{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "id": "64c956bb",
   "metadata": {},
   "outputs": [],
   "source": [
    "import torch\n",
    "import torch.nn as nn\n",
    "import numpy as np\n",
    "import matplotlib.pyplot as plt\n",
    "import scipy.io"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "id": "c1682ede",
   "metadata": {},
   "outputs": [],
   "source": [
    "# Define the LEMCell\n",
    "class LEMCell(nn.Module):\n",
    "    def __init__(self, ninp, nhid, dt):\n",
    "        super(LEMCell, self).__init__()\n",
    "        self.ninp = ninp\n",
    "        self.nhid = nhid\n",
    "        self.dt = dt\n",
    "        self.inp2hid = nn.Linear(ninp, 4 * nhid)\n",
    "        self.hid2hid = nn.Linear(nhid, 3 * nhid)\n",
    "        self.transform_z = nn.Linear(nhid, nhid)\n",
    "        self.reset_parameters()\n",
    "\n",
    "    def reset_parameters(self):\n",
    "        std = 1.0 / np.sqrt(self.nhid)\n",
    "        for w in self.parameters():\n",
    "            w.data.uniform_(-std, std)\n",
    "\n",
    "    def forward(self, x, y, z):\n",
    "        transformed_inp = self.inp2hid(x)\n",
    "        transformed_hid = self.hid2hid(y)\n",
    "        i_dt1, i_dt2, i_z, i_y = transformed_inp.chunk(4, 1)\n",
    "        h_dt1, h_dt2, h_y = transformed_hid.chunk(3, 1)\n",
    "\n",
    "        ms_dt_bar = self.dt * torch.sigmoid(i_dt1 + h_dt1)\n",
    "        ms_dt = self.dt * torch.sigmoid(i_dt2 + h_dt2)\n",
    "\n",
    "        z = (1. - ms_dt) * z + ms_dt * torch.tanh(i_y + h_y)\n",
    "        y = (1. - ms_dt_bar) * y + ms_dt_bar * torch.tanh(self.transform_z(z) + i_z)\n",
    "\n",
    "        return y, z\n",
    "\n",
    "# Define the LEM model\n",
    "class LEM(nn.Module):\n",
    "    def __init__(self, ninp, nhid, nout, dt=1.):\n",
    "        super(LEM, self).__init__()\n",
    "        self.nhid = nhid\n",
    "        self.cell = LEMCell(ninp, nhid, dt)\n",
    "        self.classifier = nn.Linear(nhid, nout)\n",
    "        self.init_weights()\n",
    "\n",
    "    def init_weights(self):\n",
    "        for name, param in self.named_parameters():\n",
    "            if 'classifier' in name and 'weight' in name:\n",
    "                nn.init.kaiming_normal_(param.data)\n",
    "\n",
    "    def forward(self, input):\n",
    "        y = input.data.new(input.size(1), self.nhid).zero_()\n",
    "        z = input.data.new(input.size(1), self.nhid).zero_()\n",
    "        for x in input:\n",
    "            y, z = self.cell(x, y, z)\n",
    "        out = self.classifier(y)\n",
    "        return out\n"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "a982afa5",
   "metadata": {},
   "source": [
    "### PINN data importing"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "id": "79da65b0",
   "metadata": {},
   "outputs": [],
   "source": [
    "# importing data\n",
    "\n",
    "# Load the .mat file\n",
    "mat_data = scipy.io.loadmat('burg.mat')\n",
    "\n",
    "# Access the variables stored in the .mat file\n",
    "# The variable names in the .mat file become keys in the loaded dictionary\n",
    "x = mat_data['x']\n",
    "t = mat_data['t']\n",
    "u = mat_data['u1']\n",
    "\n"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "bbac9f8e",
   "metadata": {},
   "source": [
    "### Exact Solution data importing"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "id": "9967dbae",
   "metadata": {},
   "outputs": [],
   "source": [
    "# importing data\n",
    "\n",
    "import torch\n",
    "import torch.nn as nn\n",
    "import numpy as np\n",
    "import time\n",
    "import scipy.io\n",
    "\n",
    "# Load the .mat file\n",
    "mat_data = scipy.io.loadmat('burgers_shock.mat')\n",
    "\n",
    "# Access the variables stored in the .mat file\n",
    "# The variable names in the .mat file become keys in the loaded dictionary\n",
    "x = mat_data['x']\n",
    "t = mat_data['t']\n",
    "u_1 = mat_data['usol']\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "id": "83a01b14",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "(256, 100)"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# Set random seed for reproducibility\n",
    "#torch.manual_seed(42)\n",
    "\n",
    "# Toy problem data\n",
    "input_size = 256\n",
    "hidden_size = 32\n",
    "output_size = 256\n",
    "sequence_length = 79\n",
    "batch_size = 1\n",
    "num_epochs = 20000\n",
    "\n",
    "# Set random seed for reproducibility\n",
    "#torch.manual_seed(42)\n",
    "u[:, 0:100].shape"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "id": "0496e4a4",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "test data shape (256,)\n",
      "input data shape (256, 79)\n",
      "Target data shape (256, 79)\n",
      "input tensor shape torch.Size([1, 79, 256])\n",
      "Target tensor shape torch.Size([1, 79, 256])\n"
     ]
    }
   ],
   "source": [
    "input_data = u[:,0:79]\n",
    "target_data = u[:,1:80]\n",
    "\n",
    "test_data = u[:,79]\n",
    "#test_target = u[:,80:100]\n",
    "\n",
    "print(\"test data shape\", test_data.shape)\n",
    "#print(\"test target shape\", test_target.shape)\n",
    "\n",
    "print(\"input data shape\",input_data.shape)\n",
    "print(\"Target data shape\",target_data.shape)\n",
    "\n",
    "# Convert data to tensors\n",
    "input_tensor = torch.tensor(input_data.T).view(batch_size, sequence_length, input_size).float()\n",
    "target_tensor = torch.tensor(target_data.T).view(batch_size, sequence_length, output_size).float()\n",
    "\n",
    "print(\"input tensor shape\",input_tensor.shape)\n",
    "print(\"Target tensor shape\",target_tensor.shape)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "id": "718d5b86",
   "metadata": {},
   "outputs": [],
   "source": [
    "# Convert test data to tensors\n",
    "test_tensor = torch.tensor(test_data.T).view(batch_size, 1, input_size).float()\n",
    "#test_target_tensor = torch.tensor(test_target.T).view(batch_size, 20, output_size).float()\n",
    "target_tensor = torch.squeeze(target_tensor)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "id": "d733ab9a",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 10/20000, Loss: 0.3878780901432037\n",
      "Epoch: 20/20000, Loss: 0.3276734948158264\n",
      "Epoch: 30/20000, Loss: 0.2693037092685699\n",
      "Epoch: 40/20000, Loss: 0.2104976326227188\n",
      "Epoch: 50/20000, Loss: 0.1560680568218231\n",
      "Epoch: 60/20000, Loss: 0.1117625683546066\n",
      "Epoch: 70/20000, Loss: 0.0791975110769272\n",
      "Epoch: 80/20000, Loss: 0.0565306805074215\n",
      "Epoch: 90/20000, Loss: 0.0415101125836372\n",
      "Epoch: 100/20000, Loss: 0.0319545343518257\n",
      "Epoch: 110/20000, Loss: 0.0261106137186289\n",
      "Epoch: 120/20000, Loss: 0.0226338282227516\n",
      "Epoch: 130/20000, Loss: 0.0205454155802727\n",
      "Epoch: 140/20000, Loss: 0.0192088093608618\n",
      "Epoch: 150/20000, Loss: 0.0182505883276463\n",
      "Epoch: 160/20000, Loss: 0.0174629092216492\n",
      "Epoch: 170/20000, Loss: 0.0167336184531450\n",
      "Epoch: 180/20000, Loss: 0.0160037949681282\n",
      "Epoch: 190/20000, Loss: 0.0152447950094938\n",
      "Epoch: 200/20000, Loss: 0.0144468937069178\n",
      "Epoch: 210/20000, Loss: 0.0136106647551060\n",
      "Epoch: 220/20000, Loss: 0.0127425612881780\n",
      "Epoch: 230/20000, Loss: 0.0118518397212029\n",
      "Epoch: 240/20000, Loss: 0.0109500000253320\n",
      "Epoch: 250/20000, Loss: 0.0100503815338016\n",
      "Epoch: 260/20000, Loss: 0.0091668386012316\n",
      "Epoch: 270/20000, Loss: 0.0083127189427614\n",
      "Epoch: 280/20000, Loss: 0.0074998927302659\n",
      "Epoch: 290/20000, Loss: 0.0067374557256699\n",
      "Epoch: 300/20000, Loss: 0.0060317199677229\n",
      "Epoch: 310/20000, Loss: 0.0053869374096394\n",
      "Epoch: 320/20000, Loss: 0.0048050284385681\n",
      "Epoch: 330/20000, Loss: 0.0042854119092226\n",
      "Epoch: 340/20000, Loss: 0.0038256682455540\n",
      "Epoch: 350/20000, Loss: 0.0034222013782710\n",
      "Epoch: 360/20000, Loss: 0.0030706301331520\n",
      "Epoch: 370/20000, Loss: 0.0027661756612360\n",
      "Epoch: 380/20000, Loss: 0.0025039727333933\n",
      "Epoch: 390/20000, Loss: 0.0022792539093643\n",
      "Epoch: 400/20000, Loss: 0.0020874852780253\n",
      "Epoch: 410/20000, Loss: 0.0019244472496212\n",
      "Epoch: 420/20000, Loss: 0.0017862812383100\n",
      "Epoch: 430/20000, Loss: 0.0016695074737072\n",
      "Epoch: 440/20000, Loss: 0.0015710243023932\n",
      "Epoch: 450/20000, Loss: 0.0014880944509059\n",
      "Epoch: 460/20000, Loss: 0.0014183248858899\n",
      "Epoch: 470/20000, Loss: 0.0013596394564956\n",
      "Epoch: 480/20000, Loss: 0.0013102516531944\n",
      "Epoch: 490/20000, Loss: 0.0012686331756413\n",
      "Epoch: 500/20000, Loss: 0.0012334848288447\n",
      "Epoch: 510/20000, Loss: 0.0012037090491503\n",
      "Epoch: 520/20000, Loss: 0.0011783821973950\n",
      "Epoch: 530/20000, Loss: 0.0011567311594263\n",
      "Epoch: 540/20000, Loss: 0.0011381102958694\n",
      "Epoch: 550/20000, Loss: 0.0011219831649214\n",
      "Epoch: 560/20000, Loss: 0.0011079050600529\n",
      "Epoch: 570/20000, Loss: 0.0010955074103549\n",
      "Epoch: 580/20000, Loss: 0.0010844860225916\n",
      "Epoch: 590/20000, Loss: 0.0010745902545750\n",
      "Epoch: 600/20000, Loss: 0.0010656132362783\n",
      "Epoch: 610/20000, Loss: 0.0010573844192550\n",
      "Epoch: 620/20000, Loss: 0.0010497635230422\n",
      "Epoch: 630/20000, Loss: 0.0010426347143948\n",
      "Epoch: 640/20000, Loss: 0.0010359025327489\n",
      "Epoch: 650/20000, Loss: 0.0010294876992702\n",
      "Epoch: 660/20000, Loss: 0.0010233251377940\n",
      "Epoch: 670/20000, Loss: 0.0010173599002883\n",
      "Epoch: 680/20000, Loss: 0.0010115468176082\n",
      "Epoch: 690/20000, Loss: 0.0010058480547741\n",
      "Epoch: 700/20000, Loss: 0.0010002312483266\n",
      "Epoch: 710/20000, Loss: 0.0009946696227416\n",
      "Epoch: 720/20000, Loss: 0.0009891402442008\n",
      "Epoch: 730/20000, Loss: 0.0009836232056841\n",
      "Epoch: 740/20000, Loss: 0.0009781017433852\n",
      "Epoch: 750/20000, Loss: 0.0009725611889735\n",
      "Epoch: 760/20000, Loss: 0.0009669883293100\n",
      "Epoch: 770/20000, Loss: 0.0009613722795621\n",
      "Epoch: 780/20000, Loss: 0.0009557026787661\n",
      "Epoch: 790/20000, Loss: 0.0009499707375653\n",
      "Epoch: 800/20000, Loss: 0.0009441684815101\n",
      "Epoch: 810/20000, Loss: 0.0009382886928506\n",
      "Epoch: 820/20000, Loss: 0.0009323441772722\n",
      "Epoch: 830/20000, Loss: 0.0009389344486408\n",
      "Epoch: 840/20000, Loss: 0.0009203304070979\n",
      "Epoch: 850/20000, Loss: 0.0009158951579593\n",
      "Epoch: 860/20000, Loss: 0.0009082959149964\n",
      "Epoch: 870/20000, Loss: 0.0009010925423354\n",
      "Epoch: 880/20000, Loss: 0.0008945424342528\n",
      "Epoch: 890/20000, Loss: 0.0008878427906893\n",
      "Epoch: 900/20000, Loss: 0.0008810057770461\n",
      "Epoch: 910/20000, Loss: 0.0008740528719500\n",
      "Epoch: 920/20000, Loss: 0.0008669786038809\n",
      "Epoch: 930/20000, Loss: 0.0008597776759416\n",
      "Epoch: 940/20000, Loss: 0.0008524446166120\n",
      "Epoch: 950/20000, Loss: 0.0008449768647552\n",
      "Epoch: 960/20000, Loss: 0.0008373736636713\n",
      "Epoch: 970/20000, Loss: 0.0008296330925077\n",
      "Epoch: 980/20000, Loss: 0.0008217541617341\n",
      "Epoch: 990/20000, Loss: 0.0008137361728586\n",
      "Epoch: 1000/20000, Loss: 0.0008055791258812\n",
      "Epoch: 1010/20000, Loss: 0.0007972825551406\n",
      "Epoch: 1020/20000, Loss: 0.0007888483232819\n",
      "Epoch: 1030/20000, Loss: 0.0007805051282048\n",
      "Epoch: 1040/20000, Loss: 0.0007976127672009\n",
      "Epoch: 1050/20000, Loss: 0.0007690045749769\n",
      "Epoch: 1060/20000, Loss: 0.0007561938837171\n",
      "Epoch: 1070/20000, Loss: 0.0007456273888238\n",
      "Epoch: 1080/20000, Loss: 0.0007357778376900\n",
      "Epoch: 1090/20000, Loss: 0.0007261707214639\n",
      "Epoch: 1100/20000, Loss: 0.0007166112773120\n",
      "Epoch: 1110/20000, Loss: 0.0007070206920616\n",
      "Epoch: 1120/20000, Loss: 0.0006973068811931\n",
      "Epoch: 1130/20000, Loss: 0.0006874863174744\n",
      "Epoch: 1140/20000, Loss: 0.0006775665679015\n",
      "Epoch: 1150/20000, Loss: 0.0006675525219180\n",
      "Epoch: 1160/20000, Loss: 0.0006574490689673\n",
      "Epoch: 1170/20000, Loss: 0.0006472631357610\n",
      "Epoch: 1180/20000, Loss: 0.0006370019400492\n",
      "Epoch: 1190/20000, Loss: 0.0006266733398661\n",
      "Epoch: 1200/20000, Loss: 0.0006162986392155\n",
      "Epoch: 1210/20000, Loss: 0.0006090874667279\n",
      "Epoch: 1220/20000, Loss: 0.0005955217056908\n",
      "Epoch: 1230/20000, Loss: 0.0005872852052562\n",
      "Epoch: 1240/20000, Loss: 0.0005755620077252\n",
      "Epoch: 1250/20000, Loss: 0.0005644662887789\n",
      "Epoch: 1260/20000, Loss: 0.0005536942044273\n",
      "Epoch: 1270/20000, Loss: 0.0005429323064163\n",
      "Epoch: 1280/20000, Loss: 0.0005322370561771\n",
      "Epoch: 1290/20000, Loss: 0.0005217322614044\n",
      "Epoch: 1300/20000, Loss: 0.0005112349172123\n",
      "Epoch: 1310/20000, Loss: 0.0005008004372939\n",
      "Epoch: 1320/20000, Loss: 0.0004904157249257\n",
      "Epoch: 1330/20000, Loss: 0.0004800954193342\n",
      "Epoch: 1340/20000, Loss: 0.0004698486882262\n",
      "Epoch: 1350/20000, Loss: 0.0004596860671882\n",
      "Epoch: 1360/20000, Loss: 0.0004496175097302\n",
      "Epoch: 1370/20000, Loss: 0.0004397767770570\n",
      "Epoch: 1380/20000, Loss: 0.0004547362914309\n",
      "Epoch: 1390/20000, Loss: 0.0004551016318146\n",
      "Epoch: 1400/20000, Loss: 0.0004201514821034\n",
      "Epoch: 1410/20000, Loss: 0.0004047363472637\n",
      "Epoch: 1420/20000, Loss: 0.0003931526734959\n",
      "Epoch: 1430/20000, Loss: 0.0003830647619907\n",
      "Epoch: 1440/20000, Loss: 0.0003736979851965\n",
      "Epoch: 1450/20000, Loss: 0.0003647880803328\n",
      "Epoch: 1460/20000, Loss: 0.0003561178455129\n",
      "Epoch: 1470/20000, Loss: 0.0003475707489997\n",
      "Epoch: 1480/20000, Loss: 0.0003392323851585\n",
      "Epoch: 1490/20000, Loss: 0.0003310697502457\n",
      "Epoch: 1500/20000, Loss: 0.0003230936708860\n",
      "Epoch: 1510/20000, Loss: 0.0003153062716592\n",
      "Epoch: 1520/20000, Loss: 0.0003077090950683\n",
      "Epoch: 1530/20000, Loss: 0.0003003046440426\n",
      "Epoch: 1540/20000, Loss: 0.0002930958871730\n",
      "Epoch: 1550/20000, Loss: 0.0002862681576516\n",
      "Epoch: 1560/20000, Loss: 0.0003216923796572\n",
      "Epoch: 1570/20000, Loss: 0.0003242011589464\n",
      "Epoch: 1580/20000, Loss: 0.0002804234100040\n",
      "Epoch: 1590/20000, Loss: 0.0002614998375066\n",
      "Epoch: 1600/20000, Loss: 0.0002542892179918\n",
      "Epoch: 1610/20000, Loss: 0.0002486548328307\n",
      "Epoch: 1620/20000, Loss: 0.0002428460429655\n",
      "Epoch: 1630/20000, Loss: 0.0002372279413976\n",
      "Epoch: 1640/20000, Loss: 0.0002318664046470\n",
      "Epoch: 1650/20000, Loss: 0.0002267212548759\n",
      "Epoch: 1660/20000, Loss: 0.0002217696019216\n",
      "Epoch: 1670/20000, Loss: 0.0002169873623643\n",
      "Epoch: 1680/20000, Loss: 0.0002123735903297\n",
      "Epoch: 1690/20000, Loss: 0.0002079259720631\n",
      "Epoch: 1700/20000, Loss: 0.0002036479418166\n",
      "Epoch: 1710/20000, Loss: 0.0002013072080445\n",
      "Epoch: 1720/20000, Loss: 0.0002120999706676\n",
      "Epoch: 1730/20000, Loss: 0.0001985652779695\n",
      "Epoch: 1740/20000, Loss: 0.0001908923877636\n",
      "Epoch: 1750/20000, Loss: 0.0001857752795331\n",
      "Epoch: 1760/20000, Loss: 0.0001816767908167\n",
      "Epoch: 1770/20000, Loss: 0.0001779038720997\n",
      "Epoch: 1780/20000, Loss: 0.0001749642106006\n",
      "Epoch: 1790/20000, Loss: 0.0001731808588374\n",
      "Epoch: 1800/20000, Loss: 0.0002069207839668\n",
      "Epoch: 1810/20000, Loss: 0.0001795855787350\n",
      "Epoch: 1820/20000, Loss: 0.0001687841577223\n",
      "Epoch: 1830/20000, Loss: 0.0001613370841369\n",
      "Epoch: 1840/20000, Loss: 0.0001593049528310\n",
      "Epoch: 1850/20000, Loss: 0.0001560990203870\n",
      "Epoch: 1860/20000, Loss: 0.0001536789350212\n",
      "Epoch: 1870/20000, Loss: 0.0001514583564131\n",
      "Epoch: 1880/20000, Loss: 0.0001493444724474\n",
      "Epoch: 1890/20000, Loss: 0.0001472905132687\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 1900/20000, Loss: 0.0001453589356970\n",
      "Epoch: 1910/20000, Loss: 0.0001447154936614\n",
      "Epoch: 1920/20000, Loss: 0.0002242638147436\n",
      "Epoch: 1930/20000, Loss: 0.0001478236663388\n",
      "Epoch: 1940/20000, Loss: 0.0001448575058021\n",
      "Epoch: 1950/20000, Loss: 0.0001375452557113\n",
      "Epoch: 1960/20000, Loss: 0.0001355870626867\n",
      "Epoch: 1970/20000, Loss: 0.0001341471215710\n",
      "Epoch: 1980/20000, Loss: 0.0001324730983470\n",
      "Epoch: 1990/20000, Loss: 0.0001310561201535\n",
      "Epoch: 2000/20000, Loss: 0.0001310039078817\n",
      "Epoch: 2010/20000, Loss: 0.0001883607474156\n",
      "Epoch: 2020/20000, Loss: 0.0001531800226076\n",
      "Epoch: 2030/20000, Loss: 0.0001282351877308\n",
      "Epoch: 2040/20000, Loss: 0.0001260597055079\n",
      "Epoch: 2050/20000, Loss: 0.0001246963074664\n",
      "Epoch: 2060/20000, Loss: 0.0001230277557625\n",
      "Epoch: 2070/20000, Loss: 0.0001219068144565\n",
      "Epoch: 2080/20000, Loss: 0.0001208429093822\n",
      "Epoch: 2090/20000, Loss: 0.0001199140169774\n",
      "Epoch: 2100/20000, Loss: 0.0001190000257338\n",
      "Epoch: 2110/20000, Loss: 0.0001181238621939\n",
      "Epoch: 2120/20000, Loss: 0.0001172785268864\n",
      "Epoch: 2130/20000, Loss: 0.0001164644563687\n",
      "Epoch: 2140/20000, Loss: 0.0001156792714028\n",
      "Epoch: 2150/20000, Loss: 0.0001149445888586\n",
      "Epoch: 2160/20000, Loss: 0.0001205632797792\n",
      "Epoch: 2170/20000, Loss: 0.0001806443178793\n",
      "Epoch: 2180/20000, Loss: 0.0001313735119766\n",
      "Epoch: 2190/20000, Loss: 0.0001132307443186\n",
      "Epoch: 2200/20000, Loss: 0.0001139504092862\n",
      "Epoch: 2210/20000, Loss: 0.0001113208199968\n",
      "Epoch: 2220/20000, Loss: 0.0001106986601371\n",
      "Epoch: 2230/20000, Loss: 0.0001098882348742\n",
      "Epoch: 2240/20000, Loss: 0.0001092574748327\n",
      "Epoch: 2250/20000, Loss: 0.0001086737465812\n",
      "Epoch: 2260/20000, Loss: 0.0001081267400878\n",
      "Epoch: 2270/20000, Loss: 0.0001076005428331\n",
      "Epoch: 2280/20000, Loss: 0.0001070940124919\n",
      "Epoch: 2290/20000, Loss: 0.0001066050172085\n",
      "Epoch: 2300/20000, Loss: 0.0001062215960701\n",
      "Epoch: 2310/20000, Loss: 0.0001122253815993\n",
      "Epoch: 2320/20000, Loss: 0.0001666373573244\n",
      "Epoch: 2330/20000, Loss: 0.0001222860882990\n",
      "Epoch: 2340/20000, Loss: 0.0001077948254533\n",
      "Epoch: 2350/20000, Loss: 0.0001046879187925\n",
      "Epoch: 2360/20000, Loss: 0.0001036236790242\n",
      "Epoch: 2370/20000, Loss: 0.0001032767177094\n",
      "Epoch: 2380/20000, Loss: 0.0001029120903695\n",
      "Epoch: 2390/20000, Loss: 0.0001024185912684\n",
      "Epoch: 2400/20000, Loss: 0.0001020164418151\n",
      "Epoch: 2410/20000, Loss: 0.0001016422975226\n",
      "Epoch: 2420/20000, Loss: 0.0001012746724882\n",
      "Epoch: 2430/20000, Loss: 0.0001009161715047\n",
      "Epoch: 2440/20000, Loss: 0.0001006196398521\n",
      "Epoch: 2450/20000, Loss: 0.0001094556646422\n",
      "Epoch: 2460/20000, Loss: 0.0001031994543155\n",
      "Epoch: 2470/20000, Loss: 0.0001006689344649\n",
      "Epoch: 2480/20000, Loss: 0.0001002694625640\n",
      "Epoch: 2490/20000, Loss: 0.0000993154608295\n",
      "Epoch: 2500/20000, Loss: 0.0000987353050732\n",
      "Epoch: 2510/20000, Loss: 0.0000983794234344\n",
      "Epoch: 2520/20000, Loss: 0.0000980406548479\n",
      "Epoch: 2530/20000, Loss: 0.0000977455201792\n",
      "Epoch: 2540/20000, Loss: 0.0000974216964096\n",
      "Epoch: 2550/20000, Loss: 0.0000971214540186\n",
      "Epoch: 2560/20000, Loss: 0.0000968366148300\n",
      "Epoch: 2570/20000, Loss: 0.0000971161571215\n",
      "Epoch: 2580/20000, Loss: 0.0001767863286659\n",
      "Epoch: 2590/20000, Loss: 0.0001346039061900\n",
      "Epoch: 2600/20000, Loss: 0.0001047187324730\n",
      "Epoch: 2610/20000, Loss: 0.0000978697062237\n",
      "Epoch: 2620/20000, Loss: 0.0000961870246101\n",
      "Epoch: 2630/20000, Loss: 0.0000953000489972\n",
      "Epoch: 2640/20000, Loss: 0.0000947865919443\n",
      "Epoch: 2650/20000, Loss: 0.0000944608400459\n",
      "Epoch: 2660/20000, Loss: 0.0000941871767282\n",
      "Epoch: 2670/20000, Loss: 0.0000939092788030\n",
      "Epoch: 2680/20000, Loss: 0.0000936443248065\n",
      "Epoch: 2690/20000, Loss: 0.0000933801493375\n",
      "Epoch: 2700/20000, Loss: 0.0000931212634896\n",
      "Epoch: 2710/20000, Loss: 0.0000928638692130\n",
      "Epoch: 2720/20000, Loss: 0.0000926086649997\n",
      "Epoch: 2730/20000, Loss: 0.0000923550542211\n",
      "Epoch: 2740/20000, Loss: 0.0000921028840821\n",
      "Epoch: 2750/20000, Loss: 0.0000918520454434\n",
      "Epoch: 2760/20000, Loss: 0.0000916027274798\n",
      "Epoch: 2770/20000, Loss: 0.0000913739058888\n",
      "Epoch: 2780/20000, Loss: 0.0000938760713325\n",
      "Epoch: 2790/20000, Loss: 0.0001262787118321\n",
      "Epoch: 2800/20000, Loss: 0.0001029930281220\n",
      "Epoch: 2810/20000, Loss: 0.0000932731345529\n",
      "Epoch: 2820/20000, Loss: 0.0000907500289031\n",
      "Epoch: 2830/20000, Loss: 0.0000900680679479\n",
      "Epoch: 2840/20000, Loss: 0.0000899210863281\n",
      "Epoch: 2850/20000, Loss: 0.0000899027290870\n",
      "Epoch: 2860/20000, Loss: 0.0000970988185145\n",
      "Epoch: 2870/20000, Loss: 0.0001012387729133\n",
      "Epoch: 2880/20000, Loss: 0.0000914656702662\n",
      "Epoch: 2890/20000, Loss: 0.0000915280324989\n",
      "Epoch: 2900/20000, Loss: 0.0000887814021553\n",
      "Epoch: 2910/20000, Loss: 0.0000883964094101\n",
      "Epoch: 2920/20000, Loss: 0.0000878372229636\n",
      "Epoch: 2930/20000, Loss: 0.0000875695186551\n",
      "Epoch: 2940/20000, Loss: 0.0000874310790095\n",
      "Epoch: 2950/20000, Loss: 0.0000964604187175\n",
      "Epoch: 2960/20000, Loss: 0.0001243692240678\n",
      "Epoch: 2970/20000, Loss: 0.0001064630196197\n",
      "Epoch: 2980/20000, Loss: 0.0000903115287656\n",
      "Epoch: 2990/20000, Loss: 0.0000866379414219\n",
      "Epoch: 3000/20000, Loss: 0.0000859761130414\n",
      "Epoch: 3010/20000, Loss: 0.0000858966013766\n",
      "Epoch: 3020/20000, Loss: 0.0000855494145071\n",
      "Epoch: 3030/20000, Loss: 0.0000851896766108\n",
      "Epoch: 3040/20000, Loss: 0.0000849725693115\n",
      "Epoch: 3050/20000, Loss: 0.0000850460564834\n",
      "Epoch: 3060/20000, Loss: 0.0001031502906699\n",
      "Epoch: 3070/20000, Loss: 0.0000942890692386\n",
      "Epoch: 3080/20000, Loss: 0.0000845118411235\n",
      "Epoch: 3090/20000, Loss: 0.0000849145726534\n",
      "Epoch: 3100/20000, Loss: 0.0000835951577756\n",
      "Epoch: 3110/20000, Loss: 0.0000835446917336\n",
      "Epoch: 3120/20000, Loss: 0.0000864968315000\n",
      "Epoch: 3130/20000, Loss: 0.0001118081054301\n",
      "Epoch: 3140/20000, Loss: 0.0000873590979609\n",
      "Epoch: 3150/20000, Loss: 0.0000827178155305\n",
      "Epoch: 3160/20000, Loss: 0.0000830304634292\n",
      "Epoch: 3170/20000, Loss: 0.0000822389629320\n",
      "Epoch: 3180/20000, Loss: 0.0000817358304630\n",
      "Epoch: 3190/20000, Loss: 0.0000814184895717\n",
      "Epoch: 3200/20000, Loss: 0.0000811934805824\n",
      "Epoch: 3210/20000, Loss: 0.0000825762326713\n",
      "Epoch: 3220/20000, Loss: 0.0001145109417848\n",
      "Epoch: 3230/20000, Loss: 0.0001070975558832\n",
      "Epoch: 3240/20000, Loss: 0.0000880368024809\n",
      "Epoch: 3250/20000, Loss: 0.0000811131176306\n",
      "Epoch: 3260/20000, Loss: 0.0000807959222584\n",
      "Epoch: 3270/20000, Loss: 0.0000797506072558\n",
      "Epoch: 3280/20000, Loss: 0.0000793928193161\n",
      "Epoch: 3290/20000, Loss: 0.0000789960104157\n",
      "Epoch: 3300/20000, Loss: 0.0000787191238487\n",
      "Epoch: 3310/20000, Loss: 0.0000787555909483\n",
      "Epoch: 3320/20000, Loss: 0.0000872874661582\n",
      "Epoch: 3330/20000, Loss: 0.0000919955273275\n",
      "Epoch: 3340/20000, Loss: 0.0000794770603534\n",
      "Epoch: 3350/20000, Loss: 0.0000804403025541\n",
      "Epoch: 3360/20000, Loss: 0.0000772927232902\n",
      "Epoch: 3370/20000, Loss: 0.0000772649800638\n",
      "Epoch: 3380/20000, Loss: 0.0000768548998167\n",
      "Epoch: 3390/20000, Loss: 0.0000767166784499\n",
      "Epoch: 3400/20000, Loss: 0.0000873848111951\n",
      "Epoch: 3410/20000, Loss: 0.0001410539989593\n",
      "Epoch: 3420/20000, Loss: 0.0000887358401087\n",
      "Epoch: 3430/20000, Loss: 0.0000812108555692\n",
      "Epoch: 3440/20000, Loss: 0.0000773160209064\n",
      "Epoch: 3450/20000, Loss: 0.0000757642119424\n",
      "Epoch: 3460/20000, Loss: 0.0000748638121877\n",
      "Epoch: 3470/20000, Loss: 0.0000745544530218\n",
      "Epoch: 3480/20000, Loss: 0.0000742281117709\n",
      "Epoch: 3490/20000, Loss: 0.0000739525712561\n",
      "Epoch: 3500/20000, Loss: 0.0000736772490200\n",
      "Epoch: 3510/20000, Loss: 0.0000734165005269\n",
      "Epoch: 3520/20000, Loss: 0.0000731661129976\n",
      "Epoch: 3530/20000, Loss: 0.0000732930202503\n",
      "Epoch: 3540/20000, Loss: 0.0000992808927549\n",
      "Epoch: 3550/20000, Loss: 0.0000837802726892\n",
      "Epoch: 3560/20000, Loss: 0.0000754213469918\n",
      "Epoch: 3570/20000, Loss: 0.0000740580435377\n",
      "Epoch: 3580/20000, Loss: 0.0000726088837837\n",
      "Epoch: 3590/20000, Loss: 0.0000717424773029\n",
      "Epoch: 3600/20000, Loss: 0.0000711727770977\n",
      "Epoch: 3610/20000, Loss: 0.0000708811712684\n",
      "Epoch: 3620/20000, Loss: 0.0000705902639311\n",
      "Epoch: 3630/20000, Loss: 0.0000718921364751\n",
      "Epoch: 3640/20000, Loss: 0.0001455270539736\n",
      "Epoch: 3650/20000, Loss: 0.0000860280924826\n",
      "Epoch: 3660/20000, Loss: 0.0000728191007511\n",
      "Epoch: 3670/20000, Loss: 0.0000698450166965\n",
      "Epoch: 3680/20000, Loss: 0.0000697124050930\n",
      "Epoch: 3690/20000, Loss: 0.0000689847220201\n",
      "Epoch: 3700/20000, Loss: 0.0000685599879944\n",
      "Epoch: 3710/20000, Loss: 0.0000682314348524\n",
      "Epoch: 3720/20000, Loss: 0.0000679422737448\n",
      "Epoch: 3730/20000, Loss: 0.0000676653799019\n",
      "Epoch: 3740/20000, Loss: 0.0000673930917401\n",
      "Epoch: 3750/20000, Loss: 0.0000671185698593\n",
      "Epoch: 3760/20000, Loss: 0.0000668616339681\n",
      "Epoch: 3770/20000, Loss: 0.0000679209260852\n",
      "Epoch: 3780/20000, Loss: 0.0001773827389115\n",
      "Epoch: 3790/20000, Loss: 0.0000742106713005\n",
      "Epoch: 3800/20000, Loss: 0.0000696018832969\n",
      "Epoch: 3810/20000, Loss: 0.0000670522567816\n",
      "Epoch: 3820/20000, Loss: 0.0000658156059217\n",
      "Epoch: 3830/20000, Loss: 0.0000651026202831\n",
      "Epoch: 3840/20000, Loss: 0.0000647677516099\n",
      "Epoch: 3850/20000, Loss: 0.0000644999672659\n",
      "Epoch: 3860/20000, Loss: 0.0000641666847514\n",
      "Epoch: 3870/20000, Loss: 0.0000640142679913\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 3880/20000, Loss: 0.0000699661250110\n",
      "Epoch: 3890/20000, Loss: 0.0000849213756737\n",
      "Epoch: 3900/20000, Loss: 0.0000648042623652\n",
      "Epoch: 3910/20000, Loss: 0.0000667831118335\n",
      "Epoch: 3920/20000, Loss: 0.0000626598994131\n",
      "Epoch: 3930/20000, Loss: 0.0000628352427157\n",
      "Epoch: 3940/20000, Loss: 0.0000626393448329\n",
      "Epoch: 3950/20000, Loss: 0.0000703738332959\n",
      "Epoch: 3960/20000, Loss: 0.0000636073527858\n",
      "Epoch: 3970/20000, Loss: 0.0000626433175057\n",
      "Epoch: 3980/20000, Loss: 0.0000616441320744\n",
      "Epoch: 3990/20000, Loss: 0.0000608428090345\n",
      "Epoch: 4000/20000, Loss: 0.0000604703855061\n",
      "Epoch: 4010/20000, Loss: 0.0000601502470090\n",
      "Epoch: 4020/20000, Loss: 0.0000602752734267\n",
      "Epoch: 4030/20000, Loss: 0.0000694843474776\n",
      "Epoch: 4040/20000, Loss: 0.0000861008520587\n",
      "Epoch: 4050/20000, Loss: 0.0000650910224067\n",
      "Epoch: 4060/20000, Loss: 0.0000598355763941\n",
      "Epoch: 4070/20000, Loss: 0.0000591969437664\n",
      "Epoch: 4080/20000, Loss: 0.0000585298294027\n",
      "Epoch: 4090/20000, Loss: 0.0000579574480071\n",
      "Epoch: 4100/20000, Loss: 0.0000577743012400\n",
      "Epoch: 4110/20000, Loss: 0.0000715172791388\n",
      "Epoch: 4120/20000, Loss: 0.0000700958044035\n",
      "Epoch: 4130/20000, Loss: 0.0000731359104975\n",
      "Epoch: 4140/20000, Loss: 0.0000602777545282\n",
      "Epoch: 4150/20000, Loss: 0.0000565846821701\n",
      "Epoch: 4160/20000, Loss: 0.0000562883396924\n",
      "Epoch: 4170/20000, Loss: 0.0000557644234505\n",
      "Epoch: 4180/20000, Loss: 0.0000552424789930\n",
      "Epoch: 4190/20000, Loss: 0.0000549580872757\n",
      "Epoch: 4200/20000, Loss: 0.0000546846022189\n",
      "Epoch: 4210/20000, Loss: 0.0000554447397008\n",
      "Epoch: 4220/20000, Loss: 0.0000927060245886\n",
      "Epoch: 4230/20000, Loss: 0.0000703457335476\n",
      "Epoch: 4240/20000, Loss: 0.0000575764897803\n",
      "Epoch: 4250/20000, Loss: 0.0000552174242330\n",
      "Epoch: 4260/20000, Loss: 0.0000535983199370\n",
      "Epoch: 4270/20000, Loss: 0.0000531479672645\n",
      "Epoch: 4280/20000, Loss: 0.0000534237733518\n",
      "Epoch: 4290/20000, Loss: 0.0000664099788992\n",
      "Epoch: 4300/20000, Loss: 0.0000576382444706\n",
      "Epoch: 4310/20000, Loss: 0.0000536935403943\n",
      "Epoch: 4320/20000, Loss: 0.0000517535081599\n",
      "Epoch: 4330/20000, Loss: 0.0000511381840624\n",
      "Epoch: 4340/20000, Loss: 0.0000509415403940\n",
      "Epoch: 4350/20000, Loss: 0.0000522934278706\n",
      "Epoch: 4360/20000, Loss: 0.0000737324080546\n",
      "Epoch: 4370/20000, Loss: 0.0000540714463568\n",
      "Epoch: 4380/20000, Loss: 0.0000504202180309\n",
      "Epoch: 4390/20000, Loss: 0.0000497791043017\n",
      "Epoch: 4400/20000, Loss: 0.0000504758791067\n",
      "Epoch: 4410/20000, Loss: 0.0000693271795171\n",
      "Epoch: 4420/20000, Loss: 0.0000522551235917\n",
      "Epoch: 4430/20000, Loss: 0.0000513768827659\n",
      "Epoch: 4440/20000, Loss: 0.0000485463751829\n",
      "Epoch: 4450/20000, Loss: 0.0000477617213619\n",
      "Epoch: 4460/20000, Loss: 0.0000482678951812\n",
      "Epoch: 4470/20000, Loss: 0.0000597474427195\n",
      "Epoch: 4480/20000, Loss: 0.0000489989324706\n",
      "Epoch: 4490/20000, Loss: 0.0000478642541566\n",
      "Epoch: 4500/20000, Loss: 0.0000485996461066\n",
      "Epoch: 4510/20000, Loss: 0.0000586801834288\n",
      "Epoch: 4520/20000, Loss: 0.0000496389729960\n",
      "Epoch: 4530/20000, Loss: 0.0000483842886752\n",
      "Epoch: 4540/20000, Loss: 0.0000457689238829\n",
      "Epoch: 4550/20000, Loss: 0.0000485198470415\n",
      "Epoch: 4560/20000, Loss: 0.0000962870835792\n",
      "Epoch: 4570/20000, Loss: 0.0000511009675392\n",
      "Epoch: 4580/20000, Loss: 0.0000496178799949\n",
      "Epoch: 4590/20000, Loss: 0.0000444474171672\n",
      "Epoch: 4600/20000, Loss: 0.0000441627635155\n",
      "Epoch: 4610/20000, Loss: 0.0000433863860962\n",
      "Epoch: 4620/20000, Loss: 0.0000429566862294\n",
      "Epoch: 4630/20000, Loss: 0.0000431241714978\n",
      "Epoch: 4640/20000, Loss: 0.0000871667580213\n",
      "Epoch: 4650/20000, Loss: 0.0000708575171302\n",
      "Epoch: 4660/20000, Loss: 0.0000514254461450\n",
      "Epoch: 4670/20000, Loss: 0.0000427758532169\n",
      "Epoch: 4680/20000, Loss: 0.0000418927447754\n",
      "Epoch: 4690/20000, Loss: 0.0000413617453887\n",
      "Epoch: 4700/20000, Loss: 0.0000409164968005\n",
      "Epoch: 4710/20000, Loss: 0.0000405539649364\n",
      "Epoch: 4720/20000, Loss: 0.0000402560472139\n",
      "Epoch: 4730/20000, Loss: 0.0000399673917855\n",
      "Epoch: 4740/20000, Loss: 0.0000400198114221\n",
      "Epoch: 4750/20000, Loss: 0.0000670125227771\n",
      "Epoch: 4760/20000, Loss: 0.0000521514302818\n",
      "Epoch: 4770/20000, Loss: 0.0000451804080512\n",
      "Epoch: 4780/20000, Loss: 0.0000407857696700\n",
      "Epoch: 4790/20000, Loss: 0.0000397674884880\n",
      "Epoch: 4800/20000, Loss: 0.0000385860585084\n",
      "Epoch: 4810/20000, Loss: 0.0000380056299036\n",
      "Epoch: 4820/20000, Loss: 0.0000377223877877\n",
      "Epoch: 4830/20000, Loss: 0.0000390019267797\n",
      "Epoch: 4840/20000, Loss: 0.0000845366303110\n",
      "Epoch: 4850/20000, Loss: 0.0000524442839378\n",
      "Epoch: 4860/20000, Loss: 0.0000370944399037\n",
      "Epoch: 4870/20000, Loss: 0.0000382966209145\n",
      "Epoch: 4880/20000, Loss: 0.0000362263817806\n",
      "Epoch: 4890/20000, Loss: 0.0000361089951184\n",
      "Epoch: 4900/20000, Loss: 0.0000356954915333\n",
      "Epoch: 4910/20000, Loss: 0.0000353680698026\n",
      "Epoch: 4920/20000, Loss: 0.0000351038688677\n",
      "Epoch: 4930/20000, Loss: 0.0000350451191480\n",
      "Epoch: 4940/20000, Loss: 0.0000792958016973\n",
      "Epoch: 4950/20000, Loss: 0.0000791263082647\n",
      "Epoch: 4960/20000, Loss: 0.0000544531758351\n",
      "Epoch: 4970/20000, Loss: 0.0000373371294700\n",
      "Epoch: 4980/20000, Loss: 0.0000347177774529\n",
      "Epoch: 4990/20000, Loss: 0.0000341062732332\n",
      "Epoch: 5000/20000, Loss: 0.0000334779797413\n",
      "Epoch: 5010/20000, Loss: 0.0000331174414896\n",
      "Epoch: 5020/20000, Loss: 0.0000328073983837\n",
      "Epoch: 5030/20000, Loss: 0.0000326413573930\n",
      "Epoch: 5040/20000, Loss: 0.0000361086167686\n",
      "Epoch: 5050/20000, Loss: 0.0000709605228622\n",
      "Epoch: 5060/20000, Loss: 0.0000386695137422\n",
      "Epoch: 5070/20000, Loss: 0.0000328673959302\n",
      "Epoch: 5080/20000, Loss: 0.0000321858206007\n",
      "Epoch: 5090/20000, Loss: 0.0000314871649607\n",
      "Epoch: 5100/20000, Loss: 0.0000310773502861\n",
      "Epoch: 5110/20000, Loss: 0.0000307094960590\n",
      "Epoch: 5120/20000, Loss: 0.0000305073008349\n",
      "Epoch: 5130/20000, Loss: 0.0000302893895423\n",
      "Epoch: 5140/20000, Loss: 0.0000313253949571\n",
      "Epoch: 5150/20000, Loss: 0.0000795676678536\n",
      "Epoch: 5160/20000, Loss: 0.0000500882088090\n",
      "Epoch: 5170/20000, Loss: 0.0000318538004649\n",
      "Epoch: 5180/20000, Loss: 0.0000315234792652\n",
      "Epoch: 5190/20000, Loss: 0.0000306173315039\n",
      "Epoch: 5200/20000, Loss: 0.0000392433248635\n",
      "Epoch: 5210/20000, Loss: 0.0000351761664206\n",
      "Epoch: 5220/20000, Loss: 0.0000312781048706\n",
      "Epoch: 5230/20000, Loss: 0.0000282378005068\n",
      "Epoch: 5240/20000, Loss: 0.0000285716178041\n",
      "Epoch: 5250/20000, Loss: 0.0000283653971564\n",
      "Epoch: 5260/20000, Loss: 0.0000317181875289\n",
      "Epoch: 5270/20000, Loss: 0.0000828405827633\n",
      "Epoch: 5280/20000, Loss: 0.0000660340301692\n",
      "Epoch: 5290/20000, Loss: 0.0000317805424856\n",
      "Epoch: 5300/20000, Loss: 0.0000297264141409\n",
      "Epoch: 5310/20000, Loss: 0.0000276897790172\n",
      "Epoch: 5320/20000, Loss: 0.0000267890172836\n",
      "Epoch: 5330/20000, Loss: 0.0000262498269876\n",
      "Epoch: 5340/20000, Loss: 0.0000259308581008\n",
      "Epoch: 5350/20000, Loss: 0.0000257182873611\n",
      "Epoch: 5360/20000, Loss: 0.0000255279519479\n",
      "Epoch: 5370/20000, Loss: 0.0000257694246102\n",
      "Epoch: 5380/20000, Loss: 0.0000508190605615\n",
      "Epoch: 5390/20000, Loss: 0.0000340234364558\n",
      "Epoch: 5400/20000, Loss: 0.0000328742207785\n",
      "Epoch: 5410/20000, Loss: 0.0000283959816443\n",
      "Epoch: 5420/20000, Loss: 0.0000259835342149\n",
      "Epoch: 5430/20000, Loss: 0.0000251635992754\n",
      "Epoch: 5440/20000, Loss: 0.0000272992983810\n",
      "Epoch: 5450/20000, Loss: 0.0000449249819212\n",
      "Epoch: 5460/20000, Loss: 0.0000375054405595\n",
      "Epoch: 5470/20000, Loss: 0.0000267111154244\n",
      "Epoch: 5480/20000, Loss: 0.0000254869028140\n",
      "Epoch: 5490/20000, Loss: 0.0000237031472352\n",
      "Epoch: 5500/20000, Loss: 0.0000239393484662\n",
      "Epoch: 5510/20000, Loss: 0.0000341646591551\n",
      "Epoch: 5520/20000, Loss: 0.0000268638414127\n",
      "Epoch: 5530/20000, Loss: 0.0000410730353906\n",
      "Epoch: 5540/20000, Loss: 0.0000258172021859\n",
      "Epoch: 5550/20000, Loss: 0.0000232280453929\n",
      "Epoch: 5560/20000, Loss: 0.0000226114188990\n",
      "Epoch: 5570/20000, Loss: 0.0000226869069593\n",
      "Epoch: 5580/20000, Loss: 0.0000219453395403\n",
      "Epoch: 5590/20000, Loss: 0.0000218328004848\n",
      "Epoch: 5600/20000, Loss: 0.0000217822180275\n",
      "Epoch: 5610/20000, Loss: 0.0000275839865935\n",
      "Epoch: 5620/20000, Loss: 0.0000872668097145\n",
      "Epoch: 5630/20000, Loss: 0.0000349097572325\n",
      "Epoch: 5640/20000, Loss: 0.0000261572440650\n",
      "Epoch: 5650/20000, Loss: 0.0000236781270360\n",
      "Epoch: 5660/20000, Loss: 0.0000208330257010\n",
      "Epoch: 5670/20000, Loss: 0.0000207151952054\n",
      "Epoch: 5680/20000, Loss: 0.0000207671437238\n",
      "Epoch: 5690/20000, Loss: 0.0000243325921474\n",
      "Epoch: 5700/20000, Loss: 0.0000625320972176\n",
      "Epoch: 5710/20000, Loss: 0.0000327972957166\n",
      "Epoch: 5720/20000, Loss: 0.0000246060790232\n",
      "Epoch: 5730/20000, Loss: 0.0000206919576158\n",
      "Epoch: 5740/20000, Loss: 0.0000197053686861\n",
      "Epoch: 5750/20000, Loss: 0.0000194806216314\n",
      "Epoch: 5760/20000, Loss: 0.0000194772383111\n",
      "Epoch: 5770/20000, Loss: 0.0000250209504884\n",
      "Epoch: 5780/20000, Loss: 0.0000555008009542\n",
      "Epoch: 5790/20000, Loss: 0.0000287358252535\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 5800/20000, Loss: 0.0000212747963815\n",
      "Epoch: 5810/20000, Loss: 0.0000191560775420\n",
      "Epoch: 5820/20000, Loss: 0.0000185883818631\n",
      "Epoch: 5830/20000, Loss: 0.0000188758695003\n",
      "Epoch: 5840/20000, Loss: 0.0000295485187962\n",
      "Epoch: 5850/20000, Loss: 0.0000423619312642\n",
      "Epoch: 5860/20000, Loss: 0.0000210884772969\n",
      "Epoch: 5870/20000, Loss: 0.0000191343806364\n",
      "Epoch: 5880/20000, Loss: 0.0000184149412235\n",
      "Epoch: 5890/20000, Loss: 0.0000176866342372\n",
      "Epoch: 5900/20000, Loss: 0.0000173672742676\n",
      "Epoch: 5910/20000, Loss: 0.0000174314245669\n",
      "Epoch: 5920/20000, Loss: 0.0000221840036829\n",
      "Epoch: 5930/20000, Loss: 0.0000556006889383\n",
      "Epoch: 5940/20000, Loss: 0.0000315903962473\n",
      "Epoch: 5950/20000, Loss: 0.0000198698999156\n",
      "Epoch: 5960/20000, Loss: 0.0000181352879736\n",
      "Epoch: 5970/20000, Loss: 0.0000174554807018\n",
      "Epoch: 5980/20000, Loss: 0.0000183216579899\n",
      "Epoch: 5990/20000, Loss: 0.0000413387788285\n",
      "Epoch: 6000/20000, Loss: 0.0000266763145191\n",
      "Epoch: 6010/20000, Loss: 0.0000195235679712\n",
      "Epoch: 6020/20000, Loss: 0.0000170676630660\n",
      "Epoch: 6030/20000, Loss: 0.0000162110427482\n",
      "Epoch: 6040/20000, Loss: 0.0000158568673214\n",
      "Epoch: 6050/20000, Loss: 0.0000167626949406\n",
      "Epoch: 6060/20000, Loss: 0.0000449968720204\n",
      "Epoch: 6070/20000, Loss: 0.0000213501480175\n",
      "Epoch: 6080/20000, Loss: 0.0000218668137677\n",
      "Epoch: 6090/20000, Loss: 0.0000166585341503\n",
      "Epoch: 6100/20000, Loss: 0.0000157752365340\n",
      "Epoch: 6110/20000, Loss: 0.0000173676289705\n",
      "Epoch: 6120/20000, Loss: 0.0000500434034620\n",
      "Epoch: 6130/20000, Loss: 0.0000241708075919\n",
      "Epoch: 6140/20000, Loss: 0.0000199403457373\n",
      "Epoch: 6150/20000, Loss: 0.0000165373639902\n",
      "Epoch: 6160/20000, Loss: 0.0000151361991811\n",
      "Epoch: 6170/20000, Loss: 0.0000148130802700\n",
      "Epoch: 6180/20000, Loss: 0.0000149787292685\n",
      "Epoch: 6190/20000, Loss: 0.0000323401327478\n",
      "Epoch: 6200/20000, Loss: 0.0000272702618531\n",
      "Epoch: 6210/20000, Loss: 0.0000247965763265\n",
      "Epoch: 6220/20000, Loss: 0.0000159065966727\n",
      "Epoch: 6230/20000, Loss: 0.0000152701722982\n",
      "Epoch: 6240/20000, Loss: 0.0000141458258440\n",
      "Epoch: 6250/20000, Loss: 0.0000141610953506\n",
      "Epoch: 6260/20000, Loss: 0.0000184405034815\n",
      "Epoch: 6270/20000, Loss: 0.0000582772518101\n",
      "Epoch: 6280/20000, Loss: 0.0000209808749787\n",
      "Epoch: 6290/20000, Loss: 0.0000160649542522\n",
      "Epoch: 6300/20000, Loss: 0.0000147839882629\n",
      "Epoch: 6310/20000, Loss: 0.0000139424928420\n",
      "Epoch: 6320/20000, Loss: 0.0000140612728501\n",
      "Epoch: 6330/20000, Loss: 0.0000294468700304\n",
      "Epoch: 6340/20000, Loss: 0.0000207320354093\n",
      "Epoch: 6350/20000, Loss: 0.0000163497770700\n",
      "Epoch: 6360/20000, Loss: 0.0000142854878504\n",
      "Epoch: 6370/20000, Loss: 0.0000138554141813\n",
      "Epoch: 6380/20000, Loss: 0.0000148389672177\n",
      "Epoch: 6390/20000, Loss: 0.0000308189628413\n",
      "Epoch: 6400/20000, Loss: 0.0000173269363586\n",
      "Epoch: 6410/20000, Loss: 0.0000161350526469\n",
      "Epoch: 6420/20000, Loss: 0.0000142335720739\n",
      "Epoch: 6430/20000, Loss: 0.0000145620761032\n",
      "Epoch: 6440/20000, Loss: 0.0000260713477473\n",
      "Epoch: 6450/20000, Loss: 0.0000211666065297\n",
      "Epoch: 6460/20000, Loss: 0.0000158914008352\n",
      "Epoch: 6470/20000, Loss: 0.0000138274417623\n",
      "Epoch: 6480/20000, Loss: 0.0000128997007778\n",
      "Epoch: 6490/20000, Loss: 0.0000134321235237\n",
      "Epoch: 6500/20000, Loss: 0.0000410832835769\n",
      "Epoch: 6510/20000, Loss: 0.0000272043234872\n",
      "Epoch: 6520/20000, Loss: 0.0000191256822291\n",
      "Epoch: 6530/20000, Loss: 0.0000128198498714\n",
      "Epoch: 6540/20000, Loss: 0.0000131684573716\n",
      "Epoch: 6550/20000, Loss: 0.0000131027300085\n",
      "Epoch: 6560/20000, Loss: 0.0000301711224893\n",
      "Epoch: 6570/20000, Loss: 0.0000208189176192\n",
      "Epoch: 6580/20000, Loss: 0.0000152515658556\n",
      "Epoch: 6590/20000, Loss: 0.0000127533467094\n",
      "Epoch: 6600/20000, Loss: 0.0000120231634355\n",
      "Epoch: 6610/20000, Loss: 0.0000116736491691\n",
      "Epoch: 6620/20000, Loss: 0.0000116043547678\n",
      "Epoch: 6630/20000, Loss: 0.0000139344747367\n",
      "Epoch: 6640/20000, Loss: 0.0000524845308973\n",
      "Epoch: 6650/20000, Loss: 0.0000238987340708\n",
      "Epoch: 6660/20000, Loss: 0.0000148298013301\n",
      "Epoch: 6670/20000, Loss: 0.0000125034548546\n",
      "Epoch: 6680/20000, Loss: 0.0000119109836305\n",
      "Epoch: 6690/20000, Loss: 0.0000127179373521\n",
      "Epoch: 6700/20000, Loss: 0.0000354317780875\n",
      "Epoch: 6710/20000, Loss: 0.0000173765929503\n",
      "Epoch: 6720/20000, Loss: 0.0000154704939632\n",
      "Epoch: 6730/20000, Loss: 0.0000211199458136\n",
      "Epoch: 6740/20000, Loss: 0.0000150623982336\n",
      "Epoch: 6750/20000, Loss: 0.0000130238313432\n",
      "Epoch: 6760/20000, Loss: 0.0000118595344247\n",
      "Epoch: 6770/20000, Loss: 0.0000154057943291\n",
      "Epoch: 6780/20000, Loss: 0.0000372765825887\n",
      "Epoch: 6790/20000, Loss: 0.0000155345114763\n",
      "Epoch: 6800/20000, Loss: 0.0000128804531414\n",
      "Epoch: 6810/20000, Loss: 0.0000114391323223\n",
      "Epoch: 6820/20000, Loss: 0.0000237687781919\n",
      "Epoch: 6830/20000, Loss: 0.0000160872732522\n",
      "Epoch: 6840/20000, Loss: 0.0000164642297023\n",
      "Epoch: 6850/20000, Loss: 0.0000136461922011\n",
      "Epoch: 6860/20000, Loss: 0.0000223301831284\n",
      "Epoch: 6870/20000, Loss: 0.0000184040145541\n",
      "Epoch: 6880/20000, Loss: 0.0000146840466186\n",
      "Epoch: 6890/20000, Loss: 0.0000112858742796\n",
      "Epoch: 6900/20000, Loss: 0.0000107519963422\n",
      "Epoch: 6910/20000, Loss: 0.0000108165377242\n",
      "Epoch: 6920/20000, Loss: 0.0000159221035574\n",
      "Epoch: 6930/20000, Loss: 0.0000502052025695\n",
      "Epoch: 6940/20000, Loss: 0.0000260816414084\n",
      "Epoch: 6950/20000, Loss: 0.0000121659713841\n",
      "Epoch: 6960/20000, Loss: 0.0000118411990115\n",
      "Epoch: 6970/20000, Loss: 0.0000104950449895\n",
      "Epoch: 6980/20000, Loss: 0.0000102929498098\n",
      "Epoch: 6990/20000, Loss: 0.0000100705674413\n",
      "Epoch: 7000/20000, Loss: 0.0000113266787594\n",
      "Epoch: 7010/20000, Loss: 0.0000821208595880\n",
      "Epoch: 7020/20000, Loss: 0.0000319536266034\n",
      "Epoch: 7030/20000, Loss: 0.0000166051140695\n",
      "Epoch: 7040/20000, Loss: 0.0000135093259814\n",
      "Epoch: 7050/20000, Loss: 0.0000107063397081\n",
      "Epoch: 7060/20000, Loss: 0.0000098929021988\n",
      "Epoch: 7070/20000, Loss: 0.0000098748187156\n",
      "Epoch: 7080/20000, Loss: 0.0000127950697788\n",
      "Epoch: 7090/20000, Loss: 0.0000600806379225\n",
      "Epoch: 7100/20000, Loss: 0.0000158066050062\n",
      "Epoch: 7110/20000, Loss: 0.0000129074414872\n",
      "Epoch: 7120/20000, Loss: 0.0000101179266494\n",
      "Epoch: 7130/20000, Loss: 0.0000104319324237\n",
      "Epoch: 7140/20000, Loss: 0.0000127166613311\n",
      "Epoch: 7150/20000, Loss: 0.0000307410882670\n",
      "Epoch: 7160/20000, Loss: 0.0000157837312145\n",
      "Epoch: 7170/20000, Loss: 0.0000109071606857\n",
      "Epoch: 7180/20000, Loss: 0.0000103810652945\n",
      "Epoch: 7190/20000, Loss: 0.0000131142378450\n",
      "Epoch: 7200/20000, Loss: 0.0000249832828558\n",
      "Epoch: 7210/20000, Loss: 0.0000143005936479\n",
      "Epoch: 7220/20000, Loss: 0.0000109133070509\n",
      "Epoch: 7230/20000, Loss: 0.0000099051831057\n",
      "Epoch: 7240/20000, Loss: 0.0000110051823867\n",
      "Epoch: 7250/20000, Loss: 0.0000231184185395\n",
      "Epoch: 7260/20000, Loss: 0.0000203057879844\n",
      "Epoch: 7270/20000, Loss: 0.0000132903505801\n",
      "Epoch: 7280/20000, Loss: 0.0000120664108181\n",
      "Epoch: 7290/20000, Loss: 0.0000249760942097\n",
      "Epoch: 7300/20000, Loss: 0.0000202223091037\n",
      "Epoch: 7310/20000, Loss: 0.0000135740028782\n",
      "Epoch: 7320/20000, Loss: 0.0000106939169200\n",
      "Epoch: 7330/20000, Loss: 0.0000100961597127\n",
      "Epoch: 7340/20000, Loss: 0.0000121193015730\n",
      "Epoch: 7350/20000, Loss: 0.0000256706516666\n",
      "Epoch: 7360/20000, Loss: 0.0000176087905857\n",
      "Epoch: 7370/20000, Loss: 0.0000112561874630\n",
      "Epoch: 7380/20000, Loss: 0.0000102673602669\n",
      "Epoch: 7390/20000, Loss: 0.0000122037545225\n",
      "Epoch: 7400/20000, Loss: 0.0000238497159444\n",
      "Epoch: 7410/20000, Loss: 0.0000333354437316\n",
      "Epoch: 7420/20000, Loss: 0.0000151122148964\n",
      "Epoch: 7430/20000, Loss: 0.0000108716048999\n",
      "Epoch: 7440/20000, Loss: 0.0000102474450614\n",
      "Epoch: 7450/20000, Loss: 0.0000092646359917\n",
      "Epoch: 7460/20000, Loss: 0.0000091792999228\n",
      "Epoch: 7470/20000, Loss: 0.0000124188300106\n",
      "Epoch: 7480/20000, Loss: 0.0000368206056010\n",
      "Epoch: 7490/20000, Loss: 0.0000230711357290\n",
      "Epoch: 7500/20000, Loss: 0.0000146743886944\n",
      "Epoch: 7510/20000, Loss: 0.0000104682603705\n",
      "Epoch: 7520/20000, Loss: 0.0000091124093160\n",
      "Epoch: 7530/20000, Loss: 0.0000096189196483\n",
      "Epoch: 7540/20000, Loss: 0.0000202812243515\n",
      "Epoch: 7550/20000, Loss: 0.0000211131336982\n",
      "Epoch: 7560/20000, Loss: 0.0000118853986351\n",
      "Epoch: 7570/20000, Loss: 0.0000099750586742\n",
      "Epoch: 7580/20000, Loss: 0.0000088185342975\n",
      "Epoch: 7590/20000, Loss: 0.0000089616132755\n",
      "Epoch: 7600/20000, Loss: 0.0000138446666824\n",
      "Epoch: 7610/20000, Loss: 0.0000554944781470\n",
      "Epoch: 7620/20000, Loss: 0.0000162378200912\n",
      "Epoch: 7630/20000, Loss: 0.0000106558582047\n",
      "Epoch: 7640/20000, Loss: 0.0000101938931039\n",
      "Epoch: 7650/20000, Loss: 0.0000097686288427\n",
      "Epoch: 7660/20000, Loss: 0.0000262133526121\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 7670/20000, Loss: 0.0000136337957883\n",
      "Epoch: 7680/20000, Loss: 0.0000120423619592\n",
      "Epoch: 7690/20000, Loss: 0.0000086872414613\n",
      "Epoch: 7700/20000, Loss: 0.0000091043430075\n",
      "Epoch: 7710/20000, Loss: 0.0000183598531294\n",
      "Epoch: 7720/20000, Loss: 0.0000221043264901\n",
      "Epoch: 7730/20000, Loss: 0.0000130765556605\n",
      "Epoch: 7740/20000, Loss: 0.0000113126288852\n",
      "Epoch: 7750/20000, Loss: 0.0000087994212663\n",
      "Epoch: 7760/20000, Loss: 0.0000089034620032\n",
      "Epoch: 7770/20000, Loss: 0.0000115080683827\n",
      "Epoch: 7780/20000, Loss: 0.0000376396565116\n",
      "Epoch: 7790/20000, Loss: 0.0000141584914672\n",
      "Epoch: 7800/20000, Loss: 0.0000107163741632\n",
      "Epoch: 7810/20000, Loss: 0.0000098386099125\n",
      "Epoch: 7820/20000, Loss: 0.0000091901511041\n",
      "Epoch: 7830/20000, Loss: 0.0000131464585138\n",
      "Epoch: 7840/20000, Loss: 0.0000212212053157\n",
      "Epoch: 7850/20000, Loss: 0.0000109826623884\n",
      "Epoch: 7860/20000, Loss: 0.0000097562169685\n",
      "Epoch: 7870/20000, Loss: 0.0000093794233180\n",
      "Epoch: 7880/20000, Loss: 0.0000114312751975\n",
      "Epoch: 7890/20000, Loss: 0.0000282784403680\n",
      "Epoch: 7900/20000, Loss: 0.0000267915511358\n",
      "Epoch: 7910/20000, Loss: 0.0000127704834085\n",
      "Epoch: 7920/20000, Loss: 0.0000111154795377\n",
      "Epoch: 7930/20000, Loss: 0.0000106070447146\n",
      "Epoch: 7940/20000, Loss: 0.0000133726280183\n",
      "Epoch: 7950/20000, Loss: 0.0000271974786301\n",
      "Epoch: 7960/20000, Loss: 0.0000093565067800\n",
      "Epoch: 7970/20000, Loss: 0.0000091620604508\n",
      "Epoch: 7980/20000, Loss: 0.0000089103550636\n",
      "Epoch: 7990/20000, Loss: 0.0000091897054517\n",
      "Epoch: 8000/20000, Loss: 0.0000194207077584\n",
      "Epoch: 8010/20000, Loss: 0.0000299995681416\n",
      "Epoch: 8020/20000, Loss: 0.0000104978671516\n",
      "Epoch: 8030/20000, Loss: 0.0000103257370938\n",
      "Epoch: 8040/20000, Loss: 0.0000091976098702\n",
      "Epoch: 8050/20000, Loss: 0.0000086311965788\n",
      "Epoch: 8060/20000, Loss: 0.0000126348513732\n",
      "Epoch: 8070/20000, Loss: 0.0000387813197449\n",
      "Epoch: 8080/20000, Loss: 0.0000165772034961\n",
      "Epoch: 8090/20000, Loss: 0.0000110064374894\n",
      "Epoch: 8100/20000, Loss: 0.0000089292589109\n",
      "Epoch: 8110/20000, Loss: 0.0000092617892733\n",
      "Epoch: 8120/20000, Loss: 0.0000237085041590\n",
      "Epoch: 8130/20000, Loss: 0.0000149532725118\n",
      "Epoch: 8140/20000, Loss: 0.0000123675454233\n",
      "Epoch: 8150/20000, Loss: 0.0000099854714790\n",
      "Epoch: 8160/20000, Loss: 0.0000203633662750\n",
      "Epoch: 8170/20000, Loss: 0.0000162916458066\n",
      "Epoch: 8180/20000, Loss: 0.0000100502275018\n",
      "Epoch: 8190/20000, Loss: 0.0000088282895376\n",
      "Epoch: 8200/20000, Loss: 0.0000081942534962\n",
      "Epoch: 8210/20000, Loss: 0.0000081367443272\n",
      "Epoch: 8220/20000, Loss: 0.0000086789386842\n",
      "Epoch: 8230/20000, Loss: 0.0000211021924770\n",
      "Epoch: 8240/20000, Loss: 0.0000191605977307\n",
      "Epoch: 8250/20000, Loss: 0.0000102941548903\n",
      "Epoch: 8260/20000, Loss: 0.0000101813429865\n",
      "Epoch: 8270/20000, Loss: 0.0000136637518153\n",
      "Epoch: 8280/20000, Loss: 0.0000173174503288\n",
      "Epoch: 8290/20000, Loss: 0.0000114523099910\n",
      "Epoch: 8300/20000, Loss: 0.0000112747475214\n",
      "Epoch: 8310/20000, Loss: 0.0000101278747024\n",
      "Epoch: 8320/20000, Loss: 0.0000131541519295\n",
      "Epoch: 8330/20000, Loss: 0.0000181435025297\n",
      "Epoch: 8340/20000, Loss: 0.0000109302673081\n",
      "Epoch: 8350/20000, Loss: 0.0000118243142424\n",
      "Epoch: 8360/20000, Loss: 0.0000150774994836\n",
      "Epoch: 8370/20000, Loss: 0.0000098442060334\n",
      "Epoch: 8380/20000, Loss: 0.0000123815980260\n",
      "Epoch: 8390/20000, Loss: 0.0000197018853214\n",
      "Epoch: 8400/20000, Loss: 0.0000150212636072\n",
      "Epoch: 8410/20000, Loss: 0.0000129201689560\n",
      "Epoch: 8420/20000, Loss: 0.0000125467022372\n",
      "Epoch: 8430/20000, Loss: 0.0000167317211890\n",
      "Epoch: 8440/20000, Loss: 0.0000246189247264\n",
      "Epoch: 8450/20000, Loss: 0.0000092518966994\n",
      "Epoch: 8460/20000, Loss: 0.0000091493384389\n",
      "Epoch: 8470/20000, Loss: 0.0000088055367087\n",
      "Epoch: 8480/20000, Loss: 0.0000158021030074\n",
      "Epoch: 8490/20000, Loss: 0.0000182299063454\n",
      "Epoch: 8500/20000, Loss: 0.0000108189688035\n",
      "Epoch: 8510/20000, Loss: 0.0000123674626593\n",
      "Epoch: 8520/20000, Loss: 0.0000102771255115\n",
      "Epoch: 8530/20000, Loss: 0.0000155903817358\n",
      "Epoch: 8540/20000, Loss: 0.0000102417598100\n",
      "Epoch: 8550/20000, Loss: 0.0000107987743831\n",
      "Epoch: 8560/20000, Loss: 0.0000137114011522\n",
      "Epoch: 8570/20000, Loss: 0.0000191354247363\n",
      "Epoch: 8580/20000, Loss: 0.0000109448719741\n",
      "Epoch: 8590/20000, Loss: 0.0000149545321619\n",
      "Epoch: 8600/20000, Loss: 0.0000123577710838\n",
      "Epoch: 8610/20000, Loss: 0.0000104732735053\n",
      "Epoch: 8620/20000, Loss: 0.0000148197586896\n",
      "Epoch: 8630/20000, Loss: 0.0000129795907924\n",
      "Epoch: 8640/20000, Loss: 0.0000094413917395\n",
      "Epoch: 8650/20000, Loss: 0.0000095363566288\n",
      "Epoch: 8660/20000, Loss: 0.0000123036306832\n",
      "Epoch: 8670/20000, Loss: 0.0000212618342630\n",
      "Epoch: 8680/20000, Loss: 0.0000204707703233\n",
      "Epoch: 8690/20000, Loss: 0.0000125196147565\n",
      "Epoch: 8700/20000, Loss: 0.0000121882058011\n",
      "Epoch: 8710/20000, Loss: 0.0000134246256493\n",
      "Epoch: 8720/20000, Loss: 0.0000165902856679\n",
      "Epoch: 8730/20000, Loss: 0.0000090723897301\n",
      "Epoch: 8740/20000, Loss: 0.0000182066523848\n",
      "Epoch: 8750/20000, Loss: 0.0000077752765719\n",
      "Epoch: 8760/20000, Loss: 0.0000090373196144\n",
      "Epoch: 8770/20000, Loss: 0.0000161172920343\n",
      "Epoch: 8780/20000, Loss: 0.0000156697497005\n",
      "Epoch: 8790/20000, Loss: 0.0000127850544231\n",
      "Epoch: 8800/20000, Loss: 0.0000215493109863\n",
      "Epoch: 8810/20000, Loss: 0.0000090513722171\n",
      "Epoch: 8820/20000, Loss: 0.0000078087696238\n",
      "Epoch: 8830/20000, Loss: 0.0000080316585809\n",
      "Epoch: 8840/20000, Loss: 0.0000078508192018\n",
      "Epoch: 8850/20000, Loss: 0.0000170736020664\n",
      "Epoch: 8860/20000, Loss: 0.0000250481643889\n",
      "Epoch: 8870/20000, Loss: 0.0000136663629746\n",
      "Epoch: 8880/20000, Loss: 0.0000114737631520\n",
      "Epoch: 8890/20000, Loss: 0.0000082800061136\n",
      "Epoch: 8900/20000, Loss: 0.0000081285743363\n",
      "Epoch: 8910/20000, Loss: 0.0000134529382194\n",
      "Epoch: 8920/20000, Loss: 0.0000206317563425\n",
      "Epoch: 8930/20000, Loss: 0.0000167029302247\n",
      "Epoch: 8940/20000, Loss: 0.0000098635618997\n",
      "Epoch: 8950/20000, Loss: 0.0000085599231170\n",
      "Epoch: 8960/20000, Loss: 0.0000108174690467\n",
      "Epoch: 8970/20000, Loss: 0.0000272886882158\n",
      "Epoch: 8980/20000, Loss: 0.0000123742265714\n",
      "Epoch: 8990/20000, Loss: 0.0000192455991055\n",
      "Epoch: 9000/20000, Loss: 0.0000097919255495\n",
      "Epoch: 9010/20000, Loss: 0.0000094105798780\n",
      "Epoch: 9020/20000, Loss: 0.0000076745964179\n",
      "Epoch: 9030/20000, Loss: 0.0000095364384833\n",
      "Epoch: 9040/20000, Loss: 0.0000204762109206\n",
      "Epoch: 9050/20000, Loss: 0.0000118129746625\n",
      "Epoch: 9060/20000, Loss: 0.0000193956784642\n",
      "Epoch: 9070/20000, Loss: 0.0000119979367810\n",
      "Epoch: 9080/20000, Loss: 0.0000098208811323\n",
      "Epoch: 9090/20000, Loss: 0.0000077158574641\n",
      "Epoch: 9100/20000, Loss: 0.0000073301275734\n",
      "Epoch: 9110/20000, Loss: 0.0000075315747381\n",
      "Epoch: 9120/20000, Loss: 0.0000220899964916\n",
      "Epoch: 9130/20000, Loss: 0.0000291558371828\n",
      "Epoch: 9140/20000, Loss: 0.0000158860311785\n",
      "Epoch: 9150/20000, Loss: 0.0000117315166790\n",
      "Epoch: 9160/20000, Loss: 0.0000087224507297\n",
      "Epoch: 9170/20000, Loss: 0.0000072367683970\n",
      "Epoch: 9180/20000, Loss: 0.0000069678440013\n",
      "Epoch: 9190/20000, Loss: 0.0000078210086940\n",
      "Epoch: 9200/20000, Loss: 0.0000305998692056\n",
      "Epoch: 9210/20000, Loss: 0.0000120133054224\n",
      "Epoch: 9220/20000, Loss: 0.0000091194733614\n",
      "Epoch: 9230/20000, Loss: 0.0000073277647061\n",
      "Epoch: 9240/20000, Loss: 0.0000072759680734\n",
      "Epoch: 9250/20000, Loss: 0.0000076295127656\n",
      "Epoch: 9260/20000, Loss: 0.0000358693541784\n",
      "Epoch: 9270/20000, Loss: 0.0000189666170627\n",
      "Epoch: 9280/20000, Loss: 0.0000092114760264\n",
      "Epoch: 9290/20000, Loss: 0.0000085034935182\n",
      "Epoch: 9300/20000, Loss: 0.0000071845302045\n",
      "Epoch: 9310/20000, Loss: 0.0000067910627877\n",
      "Epoch: 9320/20000, Loss: 0.0000067791074798\n",
      "Epoch: 9330/20000, Loss: 0.0000079949595602\n",
      "Epoch: 9340/20000, Loss: 0.0000387039654015\n",
      "Epoch: 9350/20000, Loss: 0.0000162639207701\n",
      "Epoch: 9360/20000, Loss: 0.0000079992305473\n",
      "Epoch: 9370/20000, Loss: 0.0000103553729787\n",
      "Epoch: 9380/20000, Loss: 0.0000293386092380\n",
      "Epoch: 9390/20000, Loss: 0.0000136744220072\n",
      "Epoch: 9400/20000, Loss: 0.0000093486405603\n",
      "Epoch: 9410/20000, Loss: 0.0000075671441664\n",
      "Epoch: 9420/20000, Loss: 0.0000072372449722\n",
      "Epoch: 9430/20000, Loss: 0.0000121907896755\n",
      "Epoch: 9440/20000, Loss: 0.0000345176958945\n",
      "Epoch: 9450/20000, Loss: 0.0000129474774440\n",
      "Epoch: 9460/20000, Loss: 0.0000080530544437\n",
      "Epoch: 9470/20000, Loss: 0.0000069573743531\n",
      "Epoch: 9480/20000, Loss: 0.0000068274889600\n",
      "Epoch: 9490/20000, Loss: 0.0000065641634137\n",
      "Epoch: 9500/20000, Loss: 0.0000066842235356\n",
      "Epoch: 9510/20000, Loss: 0.0000104530472527\n",
      "Epoch: 9520/20000, Loss: 0.0000352599745383\n",
      "Epoch: 9530/20000, Loss: 0.0000200500344363\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 9540/20000, Loss: 0.0000106820389192\n",
      "Epoch: 9550/20000, Loss: 0.0000074812878665\n",
      "Epoch: 9560/20000, Loss: 0.0000070494206739\n",
      "Epoch: 9570/20000, Loss: 0.0000133254579850\n",
      "Epoch: 9580/20000, Loss: 0.0000380691380997\n",
      "Epoch: 9590/20000, Loss: 0.0000107867062979\n",
      "Epoch: 9600/20000, Loss: 0.0000090917765192\n",
      "Epoch: 9610/20000, Loss: 0.0000071724925874\n",
      "Epoch: 9620/20000, Loss: 0.0000064996670517\n",
      "Epoch: 9630/20000, Loss: 0.0000062875324147\n",
      "Epoch: 9640/20000, Loss: 0.0000062647300183\n",
      "Epoch: 9650/20000, Loss: 0.0000076281303336\n",
      "Epoch: 9660/20000, Loss: 0.0000298314971587\n",
      "Epoch: 9670/20000, Loss: 0.0000154707231559\n",
      "Epoch: 9680/20000, Loss: 0.0000103827078419\n",
      "Epoch: 9690/20000, Loss: 0.0000131144215629\n",
      "Epoch: 9700/20000, Loss: 0.0000168188125826\n",
      "Epoch: 9710/20000, Loss: 0.0000102040166894\n",
      "Epoch: 9720/20000, Loss: 0.0000068890121838\n",
      "Epoch: 9730/20000, Loss: 0.0000063056868385\n",
      "Epoch: 9740/20000, Loss: 0.0000068960507633\n",
      "Epoch: 9750/20000, Loss: 0.0000196911005332\n",
      "Epoch: 9760/20000, Loss: 0.0000189661841432\n",
      "Epoch: 9770/20000, Loss: 0.0000175348759512\n",
      "Epoch: 9780/20000, Loss: 0.0000093006756288\n",
      "Epoch: 9790/20000, Loss: 0.0000075936013673\n",
      "Epoch: 9800/20000, Loss: 0.0000064568466769\n",
      "Epoch: 9810/20000, Loss: 0.0000060524180299\n",
      "Epoch: 9820/20000, Loss: 0.0000059934686760\n",
      "Epoch: 9830/20000, Loss: 0.0000069396633080\n",
      "Epoch: 9840/20000, Loss: 0.0000313174641633\n",
      "Epoch: 9850/20000, Loss: 0.0000231608792092\n",
      "Epoch: 9860/20000, Loss: 0.0000116434966912\n",
      "Epoch: 9870/20000, Loss: 0.0000080955023805\n",
      "Epoch: 9880/20000, Loss: 0.0000067336272878\n",
      "Epoch: 9890/20000, Loss: 0.0000063695847530\n",
      "Epoch: 9900/20000, Loss: 0.0000080946256276\n",
      "Epoch: 9910/20000, Loss: 0.0000199195928872\n",
      "Epoch: 9920/20000, Loss: 0.0000100608776847\n",
      "Epoch: 9930/20000, Loss: 0.0000065387444010\n",
      "Epoch: 9940/20000, Loss: 0.0000058995528889\n",
      "Epoch: 9950/20000, Loss: 0.0000065776512201\n",
      "Epoch: 9960/20000, Loss: 0.0000137238548632\n",
      "Epoch: 9970/20000, Loss: 0.0000181090654223\n",
      "Epoch: 9980/20000, Loss: 0.0000096663443401\n",
      "Epoch: 9990/20000, Loss: 0.0000084868715930\n",
      "Epoch: 10000/20000, Loss: 0.0000089927070803\n",
      "Epoch: 10010/20000, Loss: 0.0000142656363096\n",
      "Epoch: 10020/20000, Loss: 0.0000068050489972\n",
      "Epoch: 10030/20000, Loss: 0.0000113204341687\n",
      "Epoch: 10040/20000, Loss: 0.0000219090761675\n",
      "Epoch: 10050/20000, Loss: 0.0000104561959233\n",
      "Epoch: 10060/20000, Loss: 0.0000076823653217\n",
      "Epoch: 10070/20000, Loss: 0.0000064304012994\n",
      "Epoch: 10080/20000, Loss: 0.0000059757794588\n",
      "Epoch: 10090/20000, Loss: 0.0000071444369496\n",
      "Epoch: 10100/20000, Loss: 0.0000272678607871\n",
      "Epoch: 10110/20000, Loss: 0.0000207413140743\n",
      "Epoch: 10120/20000, Loss: 0.0000113742416943\n",
      "Epoch: 10130/20000, Loss: 0.0000064793025558\n",
      "Epoch: 10140/20000, Loss: 0.0000064981472860\n",
      "Epoch: 10150/20000, Loss: 0.0000059495960159\n",
      "Epoch: 10160/20000, Loss: 0.0000100125425888\n",
      "Epoch: 10170/20000, Loss: 0.0000257251831499\n",
      "Epoch: 10180/20000, Loss: 0.0000109558486656\n",
      "Epoch: 10190/20000, Loss: 0.0000072661077866\n",
      "Epoch: 10200/20000, Loss: 0.0000064639193624\n",
      "Epoch: 10210/20000, Loss: 0.0000127449284264\n",
      "Epoch: 10220/20000, Loss: 0.0000228588560276\n",
      "Epoch: 10230/20000, Loss: 0.0000088289098130\n",
      "Epoch: 10240/20000, Loss: 0.0000084536095528\n",
      "Epoch: 10250/20000, Loss: 0.0000056265607782\n",
      "Epoch: 10260/20000, Loss: 0.0000056933999986\n",
      "Epoch: 10270/20000, Loss: 0.0000054605202422\n",
      "Epoch: 10280/20000, Loss: 0.0000087311582320\n",
      "Epoch: 10290/20000, Loss: 0.0000404171405535\n",
      "Epoch: 10300/20000, Loss: 0.0000137843753691\n",
      "Epoch: 10310/20000, Loss: 0.0000073475675890\n",
      "Epoch: 10320/20000, Loss: 0.0000057998131524\n",
      "Epoch: 10330/20000, Loss: 0.0000053684898376\n",
      "Epoch: 10340/20000, Loss: 0.0000050885983001\n",
      "Epoch: 10350/20000, Loss: 0.0000049907116590\n",
      "Epoch: 10360/20000, Loss: 0.0000059185640566\n",
      "Epoch: 10370/20000, Loss: 0.0000402400146413\n",
      "Epoch: 10380/20000, Loss: 0.0000254497044807\n",
      "Epoch: 10390/20000, Loss: 0.0000167449579749\n",
      "Epoch: 10400/20000, Loss: 0.0000083471068137\n",
      "Epoch: 10410/20000, Loss: 0.0000053801477407\n",
      "Epoch: 10420/20000, Loss: 0.0000054360157264\n",
      "Epoch: 10430/20000, Loss: 0.0000060589914028\n",
      "Epoch: 10440/20000, Loss: 0.0000148739745782\n",
      "Epoch: 10450/20000, Loss: 0.0000083368304331\n",
      "Epoch: 10460/20000, Loss: 0.0000064808659772\n",
      "Epoch: 10470/20000, Loss: 0.0000058198870647\n",
      "Epoch: 10480/20000, Loss: 0.0000065929871198\n",
      "Epoch: 10490/20000, Loss: 0.0000164576103998\n",
      "Epoch: 10500/20000, Loss: 0.0000192385796254\n",
      "Epoch: 10510/20000, Loss: 0.0000092274758572\n",
      "Epoch: 10520/20000, Loss: 0.0000103294723885\n",
      "Epoch: 10530/20000, Loss: 0.0000066659326876\n",
      "Epoch: 10540/20000, Loss: 0.0000054141669352\n",
      "Epoch: 10550/20000, Loss: 0.0000047860667109\n",
      "Epoch: 10560/20000, Loss: 0.0000052235022849\n",
      "Epoch: 10570/20000, Loss: 0.0000223429797188\n",
      "Epoch: 10580/20000, Loss: 0.0000112244943011\n",
      "Epoch: 10590/20000, Loss: 0.0000138120576594\n",
      "Epoch: 10600/20000, Loss: 0.0000058636492213\n",
      "Epoch: 10610/20000, Loss: 0.0000056064932323\n",
      "Epoch: 10620/20000, Loss: 0.0000047191983867\n",
      "Epoch: 10630/20000, Loss: 0.0000045154274630\n",
      "Epoch: 10640/20000, Loss: 0.0000044063062887\n",
      "Epoch: 10650/20000, Loss: 0.0000048312044783\n",
      "Epoch: 10660/20000, Loss: 0.0000362375067198\n",
      "Epoch: 10670/20000, Loss: 0.0000278533170786\n",
      "Epoch: 10680/20000, Loss: 0.0000083145005192\n",
      "Epoch: 10690/20000, Loss: 0.0000057634351833\n",
      "Epoch: 10700/20000, Loss: 0.0000046923291848\n",
      "Epoch: 10710/20000, Loss: 0.0000044847092795\n",
      "Epoch: 10720/20000, Loss: 0.0000045375832087\n",
      "Epoch: 10730/20000, Loss: 0.0000138226641866\n",
      "Epoch: 10740/20000, Loss: 0.0000129876598294\n",
      "Epoch: 10750/20000, Loss: 0.0000079073406596\n",
      "Epoch: 10760/20000, Loss: 0.0000058018986238\n",
      "Epoch: 10770/20000, Loss: 0.0000048372262427\n",
      "Epoch: 10780/20000, Loss: 0.0000046439572543\n",
      "Epoch: 10790/20000, Loss: 0.0000119083524623\n",
      "Epoch: 10800/20000, Loss: 0.0000094169236036\n",
      "Epoch: 10810/20000, Loss: 0.0000053520639085\n",
      "Epoch: 10820/20000, Loss: 0.0000052310388128\n",
      "Epoch: 10830/20000, Loss: 0.0000045977517402\n",
      "Epoch: 10840/20000, Loss: 0.0000045429710553\n",
      "Epoch: 10850/20000, Loss: 0.0000099314229374\n",
      "Epoch: 10860/20000, Loss: 0.0000101015621112\n",
      "Epoch: 10870/20000, Loss: 0.0000049703853620\n",
      "Epoch: 10880/20000, Loss: 0.0000067718742685\n",
      "Epoch: 10890/20000, Loss: 0.0000341510021826\n",
      "Epoch: 10900/20000, Loss: 0.0000098487362266\n",
      "Epoch: 10910/20000, Loss: 0.0000070409842010\n",
      "Epoch: 10920/20000, Loss: 0.0000044110079216\n",
      "Epoch: 10930/20000, Loss: 0.0000041213447730\n",
      "Epoch: 10940/20000, Loss: 0.0000040241884562\n",
      "Epoch: 10950/20000, Loss: 0.0000038339903767\n",
      "Epoch: 10960/20000, Loss: 0.0000039468764044\n",
      "Epoch: 10970/20000, Loss: 0.0000119693713714\n",
      "Epoch: 10980/20000, Loss: 0.0000176767734956\n",
      "Epoch: 10990/20000, Loss: 0.0000150123942149\n",
      "Epoch: 11000/20000, Loss: 0.0000052063010116\n",
      "Epoch: 11010/20000, Loss: 0.0000044194262045\n",
      "Epoch: 11020/20000, Loss: 0.0000041783973757\n",
      "Epoch: 11030/20000, Loss: 0.0000038062203203\n",
      "Epoch: 11040/20000, Loss: 0.0000052358864195\n",
      "Epoch: 11050/20000, Loss: 0.0000362194441550\n",
      "Epoch: 11060/20000, Loss: 0.0000134848387461\n",
      "Epoch: 11070/20000, Loss: 0.0000067054502324\n",
      "Epoch: 11080/20000, Loss: 0.0000045670708460\n",
      "Epoch: 11090/20000, Loss: 0.0000039113147068\n",
      "Epoch: 11100/20000, Loss: 0.0000038069010770\n",
      "Epoch: 11110/20000, Loss: 0.0000055651403272\n",
      "Epoch: 11120/20000, Loss: 0.0000295002464554\n",
      "Epoch: 11130/20000, Loss: 0.0000118102534543\n",
      "Epoch: 11140/20000, Loss: 0.0000061049240685\n",
      "Epoch: 11150/20000, Loss: 0.0000041332223191\n",
      "Epoch: 11160/20000, Loss: 0.0000036401456782\n",
      "Epoch: 11170/20000, Loss: 0.0000035703117192\n",
      "Epoch: 11180/20000, Loss: 0.0000055044724832\n",
      "Epoch: 11190/20000, Loss: 0.0000310238356178\n",
      "Epoch: 11200/20000, Loss: 0.0000206601089303\n",
      "Epoch: 11210/20000, Loss: 0.0000075822085819\n",
      "Epoch: 11220/20000, Loss: 0.0000049280074563\n",
      "Epoch: 11230/20000, Loss: 0.0000040334953155\n",
      "Epoch: 11240/20000, Loss: 0.0000035393463804\n",
      "Epoch: 11250/20000, Loss: 0.0000033515727864\n",
      "Epoch: 11260/20000, Loss: 0.0000033219484976\n",
      "Epoch: 11270/20000, Loss: 0.0000043231461859\n",
      "Epoch: 11280/20000, Loss: 0.0000307792142848\n",
      "Epoch: 11290/20000, Loss: 0.0000247936277447\n",
      "Epoch: 11300/20000, Loss: 0.0000076762080425\n",
      "Epoch: 11310/20000, Loss: 0.0000049588115871\n",
      "Epoch: 11320/20000, Loss: 0.0000040043346416\n",
      "Epoch: 11330/20000, Loss: 0.0000041762764340\n",
      "Epoch: 11340/20000, Loss: 0.0000094276292657\n",
      "Epoch: 11350/20000, Loss: 0.0000115420862130\n",
      "Epoch: 11360/20000, Loss: 0.0000083539880507\n",
      "Epoch: 11370/20000, Loss: 0.0000131041961140\n",
      "Epoch: 11380/20000, Loss: 0.0000072885172813\n",
      "Epoch: 11390/20000, Loss: 0.0000050090857258\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 11400/20000, Loss: 0.0000041003813749\n",
      "Epoch: 11410/20000, Loss: 0.0000034537249576\n",
      "Epoch: 11420/20000, Loss: 0.0000047481116781\n",
      "Epoch: 11430/20000, Loss: 0.0000135645877890\n",
      "Epoch: 11440/20000, Loss: 0.0000091094825621\n",
      "Epoch: 11450/20000, Loss: 0.0000158006514539\n",
      "Epoch: 11460/20000, Loss: 0.0000113302285172\n",
      "Epoch: 11470/20000, Loss: 0.0000056200042309\n",
      "Epoch: 11480/20000, Loss: 0.0000034362774386\n",
      "Epoch: 11490/20000, Loss: 0.0000031241222587\n",
      "Epoch: 11500/20000, Loss: 0.0000031510935514\n",
      "Epoch: 11510/20000, Loss: 0.0000050531662055\n",
      "Epoch: 11520/20000, Loss: 0.0000283229837805\n",
      "Epoch: 11530/20000, Loss: 0.0000120535651149\n",
      "Epoch: 11540/20000, Loss: 0.0000048064234761\n",
      "Epoch: 11550/20000, Loss: 0.0000040048257688\n",
      "Epoch: 11560/20000, Loss: 0.0000036578644540\n",
      "Epoch: 11570/20000, Loss: 0.0000041323646656\n",
      "Epoch: 11580/20000, Loss: 0.0000123971367429\n",
      "Epoch: 11590/20000, Loss: 0.0000062827962211\n",
      "Epoch: 11600/20000, Loss: 0.0000088456490630\n",
      "Epoch: 11610/20000, Loss: 0.0000110944602056\n",
      "Epoch: 11620/20000, Loss: 0.0000088603610493\n",
      "Epoch: 11630/20000, Loss: 0.0000035948939967\n",
      "Epoch: 11640/20000, Loss: 0.0000040990930756\n",
      "Epoch: 11650/20000, Loss: 0.0000041334842535\n",
      "Epoch: 11660/20000, Loss: 0.0000139864168887\n",
      "Epoch: 11670/20000, Loss: 0.0000098243472166\n",
      "Epoch: 11680/20000, Loss: 0.0000066461470851\n",
      "Epoch: 11690/20000, Loss: 0.0000053280864449\n",
      "Epoch: 11700/20000, Loss: 0.0000072383791121\n",
      "Epoch: 11710/20000, Loss: 0.0000091925294328\n",
      "Epoch: 11720/20000, Loss: 0.0000041499324652\n",
      "Epoch: 11730/20000, Loss: 0.0000080774207163\n",
      "Epoch: 11740/20000, Loss: 0.0000084937528300\n",
      "Epoch: 11750/20000, Loss: 0.0000131925316964\n",
      "Epoch: 11760/20000, Loss: 0.0000043255417950\n",
      "Epoch: 11770/20000, Loss: 0.0000045946608225\n",
      "Epoch: 11780/20000, Loss: 0.0000066508382588\n",
      "Epoch: 11790/20000, Loss: 0.0000116365554277\n",
      "Epoch: 11800/20000, Loss: 0.0000041219091145\n",
      "Epoch: 11810/20000, Loss: 0.0000034842648802\n",
      "Epoch: 11820/20000, Loss: 0.0000126039858515\n",
      "Epoch: 11830/20000, Loss: 0.0000133290241138\n",
      "Epoch: 11840/20000, Loss: 0.0000070638689067\n",
      "Epoch: 11850/20000, Loss: 0.0000050405619731\n",
      "Epoch: 11860/20000, Loss: 0.0000093050475698\n",
      "Epoch: 11870/20000, Loss: 0.0000108834383354\n",
      "Epoch: 11880/20000, Loss: 0.0000070499731919\n",
      "Epoch: 11890/20000, Loss: 0.0000040926465772\n",
      "Epoch: 11900/20000, Loss: 0.0000025371357424\n",
      "Epoch: 11910/20000, Loss: 0.0000029670823096\n",
      "Epoch: 11920/20000, Loss: 0.0000104117971205\n",
      "Epoch: 11930/20000, Loss: 0.0000103112606666\n",
      "Epoch: 11940/20000, Loss: 0.0000090495104814\n",
      "Epoch: 11950/20000, Loss: 0.0000214058854908\n",
      "Epoch: 11960/20000, Loss: 0.0000159614501172\n",
      "Epoch: 11970/20000, Loss: 0.0000046443237807\n",
      "Epoch: 11980/20000, Loss: 0.0000042489200496\n",
      "Epoch: 11990/20000, Loss: 0.0000028270997063\n",
      "Epoch: 12000/20000, Loss: 0.0000025362246561\n",
      "Epoch: 12010/20000, Loss: 0.0000022652466214\n",
      "Epoch: 12020/20000, Loss: 0.0000022483329758\n",
      "Epoch: 12030/20000, Loss: 0.0000026053760394\n",
      "Epoch: 12040/20000, Loss: 0.0000263251295110\n",
      "Epoch: 12050/20000, Loss: 0.0000246201852860\n",
      "Epoch: 12060/20000, Loss: 0.0000069952889135\n",
      "Epoch: 12070/20000, Loss: 0.0000038895100261\n",
      "Epoch: 12080/20000, Loss: 0.0000027641358429\n",
      "Epoch: 12090/20000, Loss: 0.0000024909711556\n",
      "Epoch: 12100/20000, Loss: 0.0000022625360998\n",
      "Epoch: 12110/20000, Loss: 0.0000021677817585\n",
      "Epoch: 12120/20000, Loss: 0.0000021647124413\n",
      "Epoch: 12130/20000, Loss: 0.0000023518705348\n",
      "Epoch: 12140/20000, Loss: 0.0000115426410048\n",
      "Epoch: 12150/20000, Loss: 0.0000186169199878\n",
      "Epoch: 12160/20000, Loss: 0.0000080509234976\n",
      "Epoch: 12170/20000, Loss: 0.0000038011276047\n",
      "Epoch: 12180/20000, Loss: 0.0000030075846098\n",
      "Epoch: 12190/20000, Loss: 0.0000026619393338\n",
      "Epoch: 12200/20000, Loss: 0.0000021636424208\n",
      "Epoch: 12210/20000, Loss: 0.0000027041139674\n",
      "Epoch: 12220/20000, Loss: 0.0000131248798425\n",
      "Epoch: 12230/20000, Loss: 0.0000145496869663\n",
      "Epoch: 12240/20000, Loss: 0.0000059127219174\n",
      "Epoch: 12250/20000, Loss: 0.0000032214820749\n",
      "Epoch: 12260/20000, Loss: 0.0000024108401249\n",
      "Epoch: 12270/20000, Loss: 0.0000026448108201\n",
      "Epoch: 12280/20000, Loss: 0.0000078717785073\n",
      "Epoch: 12290/20000, Loss: 0.0000179321705218\n",
      "Epoch: 12300/20000, Loss: 0.0000065642552727\n",
      "Epoch: 12310/20000, Loss: 0.0000033394176171\n",
      "Epoch: 12320/20000, Loss: 0.0000024122036848\n",
      "Epoch: 12330/20000, Loss: 0.0000023490724743\n",
      "Epoch: 12340/20000, Loss: 0.0000065303588599\n",
      "Epoch: 12350/20000, Loss: 0.0000269124575425\n",
      "Epoch: 12360/20000, Loss: 0.0000080142553998\n",
      "Epoch: 12370/20000, Loss: 0.0000054001066019\n",
      "Epoch: 12380/20000, Loss: 0.0000030900414458\n",
      "Epoch: 12390/20000, Loss: 0.0000022114436433\n",
      "Epoch: 12400/20000, Loss: 0.0000021752575776\n",
      "Epoch: 12410/20000, Loss: 0.0000022384508611\n",
      "Epoch: 12420/20000, Loss: 0.0000042338424464\n",
      "Epoch: 12430/20000, Loss: 0.0000261158857029\n",
      "Epoch: 12440/20000, Loss: 0.0000105728449853\n",
      "Epoch: 12450/20000, Loss: 0.0000118944481073\n",
      "Epoch: 12460/20000, Loss: 0.0000033106196042\n",
      "Epoch: 12470/20000, Loss: 0.0000030511278055\n",
      "Epoch: 12480/20000, Loss: 0.0000022591934794\n",
      "Epoch: 12490/20000, Loss: 0.0000025082435968\n",
      "Epoch: 12500/20000, Loss: 0.0000054004531194\n",
      "Epoch: 12510/20000, Loss: 0.0000142346862049\n",
      "Epoch: 12520/20000, Loss: 0.0000119411515698\n",
      "Epoch: 12530/20000, Loss: 0.0000037700360735\n",
      "Epoch: 12540/20000, Loss: 0.0000046408722483\n",
      "Epoch: 12550/20000, Loss: 0.0000298804643535\n",
      "Epoch: 12560/20000, Loss: 0.0000106000397864\n",
      "Epoch: 12570/20000, Loss: 0.0000037261299894\n",
      "Epoch: 12580/20000, Loss: 0.0000026453046758\n",
      "Epoch: 12590/20000, Loss: 0.0000020564800707\n",
      "Epoch: 12600/20000, Loss: 0.0000019846079340\n",
      "Epoch: 12610/20000, Loss: 0.0000035834470964\n",
      "Epoch: 12620/20000, Loss: 0.0000412350600527\n",
      "Epoch: 12630/20000, Loss: 0.0000122599994938\n",
      "Epoch: 12640/20000, Loss: 0.0000065392232500\n",
      "Epoch: 12650/20000, Loss: 0.0000021770777039\n",
      "Epoch: 12660/20000, Loss: 0.0000024043017675\n",
      "Epoch: 12670/20000, Loss: 0.0000019147873900\n",
      "Epoch: 12680/20000, Loss: 0.0000019210988285\n",
      "Epoch: 12690/20000, Loss: 0.0000021381740680\n",
      "Epoch: 12700/20000, Loss: 0.0000083240984168\n",
      "Epoch: 12710/20000, Loss: 0.0000164173470694\n",
      "Epoch: 12720/20000, Loss: 0.0000059865546973\n",
      "Epoch: 12730/20000, Loss: 0.0000033288724808\n",
      "Epoch: 12740/20000, Loss: 0.0000022184028694\n",
      "Epoch: 12750/20000, Loss: 0.0000025993558666\n",
      "Epoch: 12760/20000, Loss: 0.0000153790369950\n",
      "Epoch: 12770/20000, Loss: 0.0000046439640755\n",
      "Epoch: 12780/20000, Loss: 0.0000062202593654\n",
      "Epoch: 12790/20000, Loss: 0.0000040953386815\n",
      "Epoch: 12800/20000, Loss: 0.0000023208203856\n",
      "Epoch: 12810/20000, Loss: 0.0000020483632852\n",
      "Epoch: 12820/20000, Loss: 0.0000023026877898\n",
      "Epoch: 12830/20000, Loss: 0.0000080968420662\n",
      "Epoch: 12840/20000, Loss: 0.0000183317624760\n",
      "Epoch: 12850/20000, Loss: 0.0000074338345257\n",
      "Epoch: 12860/20000, Loss: 0.0000051887345762\n",
      "Epoch: 12870/20000, Loss: 0.0000048571027946\n",
      "Epoch: 12880/20000, Loss: 0.0000104615519376\n",
      "Epoch: 12890/20000, Loss: 0.0000035794164432\n",
      "Epoch: 12900/20000, Loss: 0.0000027562273317\n",
      "Epoch: 12910/20000, Loss: 0.0000019909682578\n",
      "Epoch: 12920/20000, Loss: 0.0000022756494218\n",
      "Epoch: 12930/20000, Loss: 0.0000062814788180\n",
      "Epoch: 12940/20000, Loss: 0.0000287389666482\n",
      "Epoch: 12950/20000, Loss: 0.0000072328093665\n",
      "Epoch: 12960/20000, Loss: 0.0000041833836804\n",
      "Epoch: 12970/20000, Loss: 0.0000026722505027\n",
      "Epoch: 12980/20000, Loss: 0.0000024634973670\n",
      "Epoch: 12990/20000, Loss: 0.0000052554619288\n",
      "Epoch: 13000/20000, Loss: 0.0000166135341715\n",
      "Epoch: 13010/20000, Loss: 0.0000037783922835\n",
      "Epoch: 13020/20000, Loss: 0.0000019699580207\n",
      "Epoch: 13030/20000, Loss: 0.0000023539362246\n",
      "Epoch: 13040/20000, Loss: 0.0000027513679015\n",
      "Epoch: 13050/20000, Loss: 0.0000112123516374\n",
      "Epoch: 13060/20000, Loss: 0.0000133410039780\n",
      "Epoch: 13070/20000, Loss: 0.0000064811233642\n",
      "Epoch: 13080/20000, Loss: 0.0000040538111534\n",
      "Epoch: 13090/20000, Loss: 0.0000019785154564\n",
      "Epoch: 13100/20000, Loss: 0.0000017937475150\n",
      "Epoch: 13110/20000, Loss: 0.0000018258288037\n",
      "Epoch: 13120/20000, Loss: 0.0000024490836950\n",
      "Epoch: 13130/20000, Loss: 0.0000288087903755\n",
      "Epoch: 13140/20000, Loss: 0.0000193001942534\n",
      "Epoch: 13150/20000, Loss: 0.0000059022604546\n",
      "Epoch: 13160/20000, Loss: 0.0000035667635530\n",
      "Epoch: 13170/20000, Loss: 0.0000021928599381\n",
      "Epoch: 13180/20000, Loss: 0.0000019126830466\n",
      "Epoch: 13190/20000, Loss: 0.0000017677574533\n",
      "Epoch: 13200/20000, Loss: 0.0000021666749035\n",
      "Epoch: 13210/20000, Loss: 0.0000129721329358\n",
      "Epoch: 13220/20000, Loss: 0.0000029430784707\n",
      "Epoch: 13230/20000, Loss: 0.0000047244302550\n",
      "Epoch: 13240/20000, Loss: 0.0000066626612352\n",
      "Epoch: 13250/20000, Loss: 0.0000048528841035\n",
      "Epoch: 13260/20000, Loss: 0.0000057822958297\n",
      "Epoch: 13270/20000, Loss: 0.0000064272089730\n",
      "Epoch: 13280/20000, Loss: 0.0000036194956010\n",
      "Epoch: 13290/20000, Loss: 0.0000029532725421\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 13300/20000, Loss: 0.0000033211861137\n",
      "Epoch: 13310/20000, Loss: 0.0000049608347581\n",
      "Epoch: 13320/20000, Loss: 0.0000141601258292\n",
      "Epoch: 13330/20000, Loss: 0.0000130934167828\n",
      "Epoch: 13340/20000, Loss: 0.0000128585706989\n",
      "Epoch: 13350/20000, Loss: 0.0000048624160627\n",
      "Epoch: 13360/20000, Loss: 0.0000033691515000\n",
      "Epoch: 13370/20000, Loss: 0.0000021336541067\n",
      "Epoch: 13380/20000, Loss: 0.0000019328674625\n",
      "Epoch: 13390/20000, Loss: 0.0000021347116217\n",
      "Epoch: 13400/20000, Loss: 0.0000066335646807\n",
      "Epoch: 13410/20000, Loss: 0.0000117317467812\n",
      "Epoch: 13420/20000, Loss: 0.0000034573977246\n",
      "Epoch: 13430/20000, Loss: 0.0000026571733542\n",
      "Epoch: 13440/20000, Loss: 0.0000036933929550\n",
      "Epoch: 13450/20000, Loss: 0.0000289719664579\n",
      "Epoch: 13460/20000, Loss: 0.0000231393150898\n",
      "Epoch: 13470/20000, Loss: 0.0000066917668846\n",
      "Epoch: 13480/20000, Loss: 0.0000036144633668\n",
      "Epoch: 13490/20000, Loss: 0.0000022164711027\n",
      "Epoch: 13500/20000, Loss: 0.0000017391040501\n",
      "Epoch: 13510/20000, Loss: 0.0000016747820837\n",
      "Epoch: 13520/20000, Loss: 0.0000017931457705\n",
      "Epoch: 13530/20000, Loss: 0.0000046832906264\n",
      "Epoch: 13540/20000, Loss: 0.0000228623248404\n",
      "Epoch: 13550/20000, Loss: 0.0000046763989303\n",
      "Epoch: 13560/20000, Loss: 0.0000022992364848\n",
      "Epoch: 13570/20000, Loss: 0.0000024085004497\n",
      "Epoch: 13580/20000, Loss: 0.0000018201084231\n",
      "Epoch: 13590/20000, Loss: 0.0000017962756829\n",
      "Epoch: 13600/20000, Loss: 0.0000032792781894\n",
      "Epoch: 13610/20000, Loss: 0.0000146379816215\n",
      "Epoch: 13620/20000, Loss: 0.0000052596406022\n",
      "Epoch: 13630/20000, Loss: 0.0000092349910119\n",
      "Epoch: 13640/20000, Loss: 0.0000130356111185\n",
      "Epoch: 13650/20000, Loss: 0.0000033596554658\n",
      "Epoch: 13660/20000, Loss: 0.0000023360751129\n",
      "Epoch: 13670/20000, Loss: 0.0000018520811409\n",
      "Epoch: 13680/20000, Loss: 0.0000019636227080\n",
      "Epoch: 13690/20000, Loss: 0.0000044082471504\n",
      "Epoch: 13700/20000, Loss: 0.0000240874032897\n",
      "Epoch: 13710/20000, Loss: 0.0000142410417538\n",
      "Epoch: 13720/20000, Loss: 0.0000053091998780\n",
      "Epoch: 13730/20000, Loss: 0.0000023016566502\n",
      "Epoch: 13740/20000, Loss: 0.0000025139922855\n",
      "Epoch: 13750/20000, Loss: 0.0000028339784421\n",
      "Epoch: 13760/20000, Loss: 0.0000087626995082\n",
      "Epoch: 13770/20000, Loss: 0.0000099168628367\n",
      "Epoch: 13780/20000, Loss: 0.0000059912808865\n",
      "Epoch: 13790/20000, Loss: 0.0000043114619075\n",
      "Epoch: 13800/20000, Loss: 0.0000028734834814\n",
      "Epoch: 13810/20000, Loss: 0.0000019347842226\n",
      "Epoch: 13820/20000, Loss: 0.0000040363051994\n",
      "Epoch: 13830/20000, Loss: 0.0000107584555735\n",
      "Epoch: 13840/20000, Loss: 0.0000056900034906\n",
      "Epoch: 13850/20000, Loss: 0.0000084413040895\n",
      "Epoch: 13860/20000, Loss: 0.0000074952404248\n",
      "Epoch: 13870/20000, Loss: 0.0000108819822344\n",
      "Epoch: 13880/20000, Loss: 0.0000058350901782\n",
      "Epoch: 13890/20000, Loss: 0.0000029463762985\n",
      "Epoch: 13900/20000, Loss: 0.0000021411367470\n",
      "Epoch: 13910/20000, Loss: 0.0000018962196009\n",
      "Epoch: 13920/20000, Loss: 0.0000024860416943\n",
      "Epoch: 13930/20000, Loss: 0.0000163098338817\n",
      "Epoch: 13940/20000, Loss: 0.0000142256176332\n",
      "Epoch: 13950/20000, Loss: 0.0000067999926614\n",
      "Epoch: 13960/20000, Loss: 0.0000041938933464\n",
      "Epoch: 13970/20000, Loss: 0.0000024107337140\n",
      "Epoch: 13980/20000, Loss: 0.0000016732027461\n",
      "Epoch: 13990/20000, Loss: 0.0000017837705855\n",
      "Epoch: 14000/20000, Loss: 0.0000042795873014\n",
      "Epoch: 14010/20000, Loss: 0.0000187387722690\n",
      "Epoch: 14020/20000, Loss: 0.0000077583154052\n",
      "Epoch: 14030/20000, Loss: 0.0000055776886256\n",
      "Epoch: 14040/20000, Loss: 0.0000028617234875\n",
      "Epoch: 14050/20000, Loss: 0.0000020038521598\n",
      "Epoch: 14060/20000, Loss: 0.0000018820478545\n",
      "Epoch: 14070/20000, Loss: 0.0000027676287573\n",
      "Epoch: 14080/20000, Loss: 0.0000365980667993\n",
      "Epoch: 14090/20000, Loss: 0.0000156310852617\n",
      "Epoch: 14100/20000, Loss: 0.0000035090267829\n",
      "Epoch: 14110/20000, Loss: 0.0000035984978695\n",
      "Epoch: 14120/20000, Loss: 0.0000016888239998\n",
      "Epoch: 14130/20000, Loss: 0.0000017142430124\n",
      "Epoch: 14140/20000, Loss: 0.0000016302035419\n",
      "Epoch: 14150/20000, Loss: 0.0000019262570277\n",
      "Epoch: 14160/20000, Loss: 0.0000123463705677\n",
      "Epoch: 14170/20000, Loss: 0.0000096974463304\n",
      "Epoch: 14180/20000, Loss: 0.0000049318314268\n",
      "Epoch: 14190/20000, Loss: 0.0000033961564441\n",
      "Epoch: 14200/20000, Loss: 0.0000023043176043\n",
      "Epoch: 14210/20000, Loss: 0.0000020447948827\n",
      "Epoch: 14220/20000, Loss: 0.0000045293086259\n",
      "Epoch: 14230/20000, Loss: 0.0000199450296350\n",
      "Epoch: 14240/20000, Loss: 0.0000063730703914\n",
      "Epoch: 14250/20000, Loss: 0.0000047305993576\n",
      "Epoch: 14260/20000, Loss: 0.0000033527221603\n",
      "Epoch: 14270/20000, Loss: 0.0000028043614293\n",
      "Epoch: 14280/20000, Loss: 0.0000040217296373\n",
      "Epoch: 14290/20000, Loss: 0.0000105074168459\n",
      "Epoch: 14300/20000, Loss: 0.0000097278134490\n",
      "Epoch: 14310/20000, Loss: 0.0000029016666758\n",
      "Epoch: 14320/20000, Loss: 0.0000030336075270\n",
      "Epoch: 14330/20000, Loss: 0.0000022531007744\n",
      "Epoch: 14340/20000, Loss: 0.0000023930997486\n",
      "Epoch: 14350/20000, Loss: 0.0000061468058448\n",
      "Epoch: 14360/20000, Loss: 0.0000084338716988\n",
      "Epoch: 14370/20000, Loss: 0.0000035483824377\n",
      "Epoch: 14380/20000, Loss: 0.0000160278868861\n",
      "Epoch: 14390/20000, Loss: 0.0000106581628643\n",
      "Epoch: 14400/20000, Loss: 0.0000049973714340\n",
      "Epoch: 14410/20000, Loss: 0.0000027629205306\n",
      "Epoch: 14420/20000, Loss: 0.0000020955403670\n",
      "Epoch: 14430/20000, Loss: 0.0000016297818775\n",
      "Epoch: 14440/20000, Loss: 0.0000017362976905\n",
      "Epoch: 14450/20000, Loss: 0.0000065347517193\n",
      "Epoch: 14460/20000, Loss: 0.0000153337696247\n",
      "Epoch: 14470/20000, Loss: 0.0000074141839832\n",
      "Epoch: 14480/20000, Loss: 0.0000077277591117\n",
      "Epoch: 14490/20000, Loss: 0.0000030787696232\n",
      "Epoch: 14500/20000, Loss: 0.0000020230388600\n",
      "Epoch: 14510/20000, Loss: 0.0000019608373805\n",
      "Epoch: 14520/20000, Loss: 0.0000017789001276\n",
      "Epoch: 14530/20000, Loss: 0.0000042372198550\n",
      "Epoch: 14540/20000, Loss: 0.0000214097999560\n",
      "Epoch: 14550/20000, Loss: 0.0000120383247122\n",
      "Epoch: 14560/20000, Loss: 0.0000027171099646\n",
      "Epoch: 14570/20000, Loss: 0.0000022080350845\n",
      "Epoch: 14580/20000, Loss: 0.0000021941070827\n",
      "Epoch: 14590/20000, Loss: 0.0000024522043987\n",
      "Epoch: 14600/20000, Loss: 0.0000082440874394\n",
      "Epoch: 14610/20000, Loss: 0.0000109676557258\n",
      "Epoch: 14620/20000, Loss: 0.0000171535120899\n",
      "Epoch: 14630/20000, Loss: 0.0000060154834500\n",
      "Epoch: 14640/20000, Loss: 0.0000031243021112\n",
      "Epoch: 14650/20000, Loss: 0.0000024096559628\n",
      "Epoch: 14660/20000, Loss: 0.0000018097144903\n",
      "Epoch: 14670/20000, Loss: 0.0000016269991647\n",
      "Epoch: 14680/20000, Loss: 0.0000024551216029\n",
      "Epoch: 14690/20000, Loss: 0.0000176257599378\n",
      "Epoch: 14700/20000, Loss: 0.0000102170724858\n",
      "Epoch: 14710/20000, Loss: 0.0000073892488217\n",
      "Epoch: 14720/20000, Loss: 0.0000042306919568\n",
      "Epoch: 14730/20000, Loss: 0.0000021411954094\n",
      "Epoch: 14740/20000, Loss: 0.0000026055104172\n",
      "Epoch: 14750/20000, Loss: 0.0000064168852987\n",
      "Epoch: 14760/20000, Loss: 0.0000162423948495\n",
      "Epoch: 14770/20000, Loss: 0.0000129040890897\n",
      "Epoch: 14780/20000, Loss: 0.0000060538400248\n",
      "Epoch: 14790/20000, Loss: 0.0000036593226014\n",
      "Epoch: 14800/20000, Loss: 0.0000022607957817\n",
      "Epoch: 14810/20000, Loss: 0.0000018272022544\n",
      "Epoch: 14820/20000, Loss: 0.0000016372440541\n",
      "Epoch: 14830/20000, Loss: 0.0000016789206256\n",
      "Epoch: 14840/20000, Loss: 0.0000035894340726\n",
      "Epoch: 14850/20000, Loss: 0.0000267383766186\n",
      "Epoch: 14860/20000, Loss: 0.0000094201304819\n",
      "Epoch: 14870/20000, Loss: 0.0000060319848671\n",
      "Epoch: 14880/20000, Loss: 0.0000043403106247\n",
      "Epoch: 14890/20000, Loss: 0.0000022289843855\n",
      "Epoch: 14900/20000, Loss: 0.0000017839358861\n",
      "Epoch: 14910/20000, Loss: 0.0000028589759040\n",
      "Epoch: 14920/20000, Loss: 0.0000251780220424\n",
      "Epoch: 14930/20000, Loss: 0.0000161117441166\n",
      "Epoch: 14940/20000, Loss: 0.0000044882872317\n",
      "Epoch: 14950/20000, Loss: 0.0000021457240109\n",
      "Epoch: 14960/20000, Loss: 0.0000021261423626\n",
      "Epoch: 14970/20000, Loss: 0.0000016547428459\n",
      "Epoch: 14980/20000, Loss: 0.0000015876477164\n",
      "Epoch: 14990/20000, Loss: 0.0000016293593035\n",
      "Epoch: 15000/20000, Loss: 0.0000033751261981\n",
      "Epoch: 15010/20000, Loss: 0.0000231578160310\n",
      "Epoch: 15020/20000, Loss: 0.0000080420695667\n",
      "Epoch: 15030/20000, Loss: 0.0000038115254029\n",
      "Epoch: 15040/20000, Loss: 0.0000078103876149\n",
      "Epoch: 15050/20000, Loss: 0.0000030679454994\n",
      "Epoch: 15060/20000, Loss: 0.0000027638916436\n",
      "Epoch: 15070/20000, Loss: 0.0000020782788397\n",
      "Epoch: 15080/20000, Loss: 0.0000064704240685\n",
      "Epoch: 15090/20000, Loss: 0.0000075340608419\n",
      "Epoch: 15100/20000, Loss: 0.0000084259554569\n",
      "Epoch: 15110/20000, Loss: 0.0000047230037126\n",
      "Epoch: 15120/20000, Loss: 0.0000026413497380\n",
      "Epoch: 15130/20000, Loss: 0.0000017273981712\n",
      "Epoch: 15140/20000, Loss: 0.0000021918915536\n",
      "Epoch: 15150/20000, Loss: 0.0000105543940663\n",
      "Epoch: 15160/20000, Loss: 0.0000132658469738\n",
      "Epoch: 15170/20000, Loss: 0.0000034422123463\n",
      "Epoch: 15180/20000, Loss: 0.0000030566170608\n",
      "Epoch: 15190/20000, Loss: 0.0000021792236566\n",
      "Epoch: 15200/20000, Loss: 0.0000017683710212\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 15210/20000, Loss: 0.0000015872783479\n",
      "Epoch: 15220/20000, Loss: 0.0000021816711069\n",
      "Epoch: 15230/20000, Loss: 0.0000195040993276\n",
      "Epoch: 15240/20000, Loss: 0.0000162872547662\n",
      "Epoch: 15250/20000, Loss: 0.0000049071513786\n",
      "Epoch: 15260/20000, Loss: 0.0000034005313410\n",
      "Epoch: 15270/20000, Loss: 0.0000023011273242\n",
      "Epoch: 15280/20000, Loss: 0.0000016116962342\n",
      "Epoch: 15290/20000, Loss: 0.0000015592166847\n",
      "Epoch: 15300/20000, Loss: 0.0000016323192540\n",
      "Epoch: 15310/20000, Loss: 0.0000047393282330\n",
      "Epoch: 15320/20000, Loss: 0.0000216166063183\n",
      "Epoch: 15330/20000, Loss: 0.0000132078675961\n",
      "Epoch: 15340/20000, Loss: 0.0000044726989472\n",
      "Epoch: 15350/20000, Loss: 0.0000023689021873\n",
      "Epoch: 15360/20000, Loss: 0.0000018499770249\n",
      "Epoch: 15370/20000, Loss: 0.0000017109073269\n",
      "Epoch: 15380/20000, Loss: 0.0000018824538301\n",
      "Epoch: 15390/20000, Loss: 0.0000053722073972\n",
      "Epoch: 15400/20000, Loss: 0.0000178134105226\n",
      "Epoch: 15410/20000, Loss: 0.0000049245463742\n",
      "Epoch: 15420/20000, Loss: 0.0000027594144285\n",
      "Epoch: 15430/20000, Loss: 0.0000018336467065\n",
      "Epoch: 15440/20000, Loss: 0.0000017215821799\n",
      "Epoch: 15450/20000, Loss: 0.0000014938057120\n",
      "Epoch: 15460/20000, Loss: 0.0000016892743133\n",
      "Epoch: 15470/20000, Loss: 0.0000074348013186\n",
      "Epoch: 15480/20000, Loss: 0.0000138907380460\n",
      "Epoch: 15490/20000, Loss: 0.0000105522440208\n",
      "Epoch: 15500/20000, Loss: 0.0000050681337598\n",
      "Epoch: 15510/20000, Loss: 0.0000025087213089\n",
      "Epoch: 15520/20000, Loss: 0.0000017509604504\n",
      "Epoch: 15530/20000, Loss: 0.0000015544812868\n",
      "Epoch: 15540/20000, Loss: 0.0000018356751070\n",
      "Epoch: 15550/20000, Loss: 0.0000102783587863\n",
      "Epoch: 15560/20000, Loss: 0.0000088612423497\n",
      "Epoch: 15570/20000, Loss: 0.0000060830038819\n",
      "Epoch: 15580/20000, Loss: 0.0000035667480915\n",
      "Epoch: 15590/20000, Loss: 0.0000018753893301\n",
      "Epoch: 15600/20000, Loss: 0.0000015578210650\n",
      "Epoch: 15610/20000, Loss: 0.0000019412827896\n",
      "Epoch: 15620/20000, Loss: 0.0000067392079472\n",
      "Epoch: 15630/20000, Loss: 0.0000081838325059\n",
      "Epoch: 15640/20000, Loss: 0.0000049469927035\n",
      "Epoch: 15650/20000, Loss: 0.0000065213844209\n",
      "Epoch: 15660/20000, Loss: 0.0000101120504041\n",
      "Epoch: 15670/20000, Loss: 0.0000051508045544\n",
      "Epoch: 15680/20000, Loss: 0.0000022248602818\n",
      "Epoch: 15690/20000, Loss: 0.0000024739838409\n",
      "Epoch: 15700/20000, Loss: 0.0000025171577818\n",
      "Epoch: 15710/20000, Loss: 0.0000066091756707\n",
      "Epoch: 15720/20000, Loss: 0.0000101761843325\n",
      "Epoch: 15730/20000, Loss: 0.0000059687754401\n",
      "Epoch: 15740/20000, Loss: 0.0000032133259538\n",
      "Epoch: 15750/20000, Loss: 0.0000030241660625\n",
      "Epoch: 15760/20000, Loss: 0.0000043769123295\n",
      "Epoch: 15770/20000, Loss: 0.0000050797693802\n",
      "Epoch: 15780/20000, Loss: 0.0000145863332364\n",
      "Epoch: 15790/20000, Loss: 0.0000058591494962\n",
      "Epoch: 15800/20000, Loss: 0.0000033332985367\n",
      "Epoch: 15810/20000, Loss: 0.0000021072544314\n",
      "Epoch: 15820/20000, Loss: 0.0000025644894777\n",
      "Epoch: 15830/20000, Loss: 0.0000073270452958\n",
      "Epoch: 15840/20000, Loss: 0.0000068614926931\n",
      "Epoch: 15850/20000, Loss: 0.0000084100101958\n",
      "Epoch: 15860/20000, Loss: 0.0000082725346147\n",
      "Epoch: 15870/20000, Loss: 0.0000039302990444\n",
      "Epoch: 15880/20000, Loss: 0.0000021302062123\n",
      "Epoch: 15890/20000, Loss: 0.0000019222250103\n",
      "Epoch: 15900/20000, Loss: 0.0000027120522645\n",
      "Epoch: 15910/20000, Loss: 0.0000097671381809\n",
      "Epoch: 15920/20000, Loss: 0.0000101788491520\n",
      "Epoch: 15930/20000, Loss: 0.0000048972751756\n",
      "Epoch: 15940/20000, Loss: 0.0000023009206416\n",
      "Epoch: 15950/20000, Loss: 0.0000020725431114\n",
      "Epoch: 15960/20000, Loss: 0.0000019726044229\n",
      "Epoch: 15970/20000, Loss: 0.0000034982808756\n",
      "Epoch: 15980/20000, Loss: 0.0000139029525599\n",
      "Epoch: 15990/20000, Loss: 0.0000057680094869\n",
      "Epoch: 16000/20000, Loss: 0.0000039385404307\n",
      "Epoch: 16010/20000, Loss: 0.0000064403025135\n",
      "Epoch: 16020/20000, Loss: 0.0000057265342548\n",
      "Epoch: 16030/20000, Loss: 0.0000089824416136\n",
      "Epoch: 16040/20000, Loss: 0.0000038362759369\n",
      "Epoch: 16050/20000, Loss: 0.0000025389406346\n",
      "Epoch: 16060/20000, Loss: 0.0000028588221994\n",
      "Epoch: 16070/20000, Loss: 0.0000062415765569\n",
      "Epoch: 16080/20000, Loss: 0.0000044456810429\n",
      "Epoch: 16090/20000, Loss: 0.0000067385012699\n",
      "Epoch: 16100/20000, Loss: 0.0000125726046463\n",
      "Epoch: 16110/20000, Loss: 0.0000102820677057\n",
      "Epoch: 16120/20000, Loss: 0.0000042821875468\n",
      "Epoch: 16130/20000, Loss: 0.0000030910125588\n",
      "Epoch: 16140/20000, Loss: 0.0000027108767426\n",
      "Epoch: 16150/20000, Loss: 0.0000035527664295\n",
      "Epoch: 16160/20000, Loss: 0.0000061167220338\n",
      "Epoch: 16170/20000, Loss: 0.0000093959597507\n",
      "Epoch: 16180/20000, Loss: 0.0000027619219054\n",
      "Epoch: 16190/20000, Loss: 0.0000032751972867\n",
      "Epoch: 16200/20000, Loss: 0.0000020939780825\n",
      "Epoch: 16210/20000, Loss: 0.0000025991791972\n",
      "Epoch: 16220/20000, Loss: 0.0000128538358695\n",
      "Epoch: 16230/20000, Loss: 0.0000089249133453\n",
      "Epoch: 16240/20000, Loss: 0.0000044718321988\n",
      "Epoch: 16250/20000, Loss: 0.0000022555852865\n",
      "Epoch: 16260/20000, Loss: 0.0000024489281714\n",
      "Epoch: 16270/20000, Loss: 0.0000028969261621\n",
      "Epoch: 16280/20000, Loss: 0.0000099880953712\n",
      "Epoch: 16290/20000, Loss: 0.0000030987009723\n",
      "Epoch: 16300/20000, Loss: 0.0000026451480153\n",
      "Epoch: 16310/20000, Loss: 0.0000040171908040\n",
      "Epoch: 16320/20000, Loss: 0.0000140387510328\n",
      "Epoch: 16330/20000, Loss: 0.0000061370692492\n",
      "Epoch: 16340/20000, Loss: 0.0000025717197332\n",
      "Epoch: 16350/20000, Loss: 0.0000023748168587\n",
      "Epoch: 16360/20000, Loss: 0.0000018184040300\n",
      "Epoch: 16370/20000, Loss: 0.0000027703349588\n",
      "Epoch: 16380/20000, Loss: 0.0000169647810253\n",
      "Epoch: 16390/20000, Loss: 0.0000086198760982\n",
      "Epoch: 16400/20000, Loss: 0.0000035690602544\n",
      "Epoch: 16410/20000, Loss: 0.0000022068129510\n",
      "Epoch: 16420/20000, Loss: 0.0000018085422653\n",
      "Epoch: 16430/20000, Loss: 0.0000026292395887\n",
      "Epoch: 16440/20000, Loss: 0.0000159401170094\n",
      "Epoch: 16450/20000, Loss: 0.0000044484304453\n",
      "Epoch: 16460/20000, Loss: 0.0000035056432353\n",
      "Epoch: 16470/20000, Loss: 0.0000032670150176\n",
      "Epoch: 16480/20000, Loss: 0.0000032713253404\n",
      "Epoch: 16490/20000, Loss: 0.0000027079120173\n",
      "Epoch: 16500/20000, Loss: 0.0000032195066524\n",
      "Epoch: 16510/20000, Loss: 0.0000125480419229\n",
      "Epoch: 16520/20000, Loss: 0.0000149472525663\n",
      "Epoch: 16530/20000, Loss: 0.0000060404736359\n",
      "Epoch: 16540/20000, Loss: 0.0000027338658128\n",
      "Epoch: 16550/20000, Loss: 0.0000021440077944\n",
      "Epoch: 16560/20000, Loss: 0.0000016681855186\n",
      "Epoch: 16570/20000, Loss: 0.0000016372831624\n",
      "Epoch: 16580/20000, Loss: 0.0000047894613999\n",
      "Epoch: 16590/20000, Loss: 0.0000144528339661\n",
      "Epoch: 16600/20000, Loss: 0.0000042573365135\n",
      "Epoch: 16610/20000, Loss: 0.0000030927210446\n",
      "Epoch: 16620/20000, Loss: 0.0000023158668228\n",
      "Epoch: 16630/20000, Loss: 0.0000017805207335\n",
      "Epoch: 16640/20000, Loss: 0.0000025309877856\n",
      "Epoch: 16650/20000, Loss: 0.0000132597315314\n",
      "Epoch: 16660/20000, Loss: 0.0000044463909035\n",
      "Epoch: 16670/20000, Loss: 0.0000032426935377\n",
      "Epoch: 16680/20000, Loss: 0.0000021642224510\n",
      "Epoch: 16690/20000, Loss: 0.0000027671731004\n",
      "Epoch: 16700/20000, Loss: 0.0000158006387210\n",
      "Epoch: 16710/20000, Loss: 0.0000075234934229\n",
      "Epoch: 16720/20000, Loss: 0.0000039919214032\n",
      "Epoch: 16730/20000, Loss: 0.0000022364909000\n",
      "Epoch: 16740/20000, Loss: 0.0000035946359276\n",
      "Epoch: 16750/20000, Loss: 0.0000075431867117\n",
      "Epoch: 16760/20000, Loss: 0.0000067471946750\n",
      "Epoch: 16770/20000, Loss: 0.0000043375516725\n",
      "Epoch: 16780/20000, Loss: 0.0000024749724616\n",
      "Epoch: 16790/20000, Loss: 0.0000027850906008\n",
      "Epoch: 16800/20000, Loss: 0.0000039737233237\n",
      "Epoch: 16810/20000, Loss: 0.0000114343074529\n",
      "Epoch: 16820/20000, Loss: 0.0000059461754063\n",
      "Epoch: 16830/20000, Loss: 0.0000028701949759\n",
      "Epoch: 16840/20000, Loss: 0.0000039165984163\n",
      "Epoch: 16850/20000, Loss: 0.0000063488937485\n",
      "Epoch: 16860/20000, Loss: 0.0000020839379431\n",
      "Epoch: 16870/20000, Loss: 0.0000025096628633\n",
      "Epoch: 16880/20000, Loss: 0.0000029705856832\n",
      "Epoch: 16890/20000, Loss: 0.0000145037311086\n",
      "Epoch: 16900/20000, Loss: 0.0000215145664697\n",
      "Epoch: 16910/20000, Loss: 0.0000092244226835\n",
      "Epoch: 16920/20000, Loss: 0.0000030984058412\n",
      "Epoch: 16930/20000, Loss: 0.0000021907676455\n",
      "Epoch: 16940/20000, Loss: 0.0000017232172240\n",
      "Epoch: 16950/20000, Loss: 0.0000014832255602\n",
      "Epoch: 16960/20000, Loss: 0.0000018010757685\n",
      "Epoch: 16970/20000, Loss: 0.0000070930664151\n",
      "Epoch: 16980/20000, Loss: 0.0000137009456012\n",
      "Epoch: 16990/20000, Loss: 0.0000023088418857\n",
      "Epoch: 17000/20000, Loss: 0.0000038859038796\n",
      "Epoch: 17010/20000, Loss: 0.0000018053685835\n",
      "Epoch: 17020/20000, Loss: 0.0000016444944322\n",
      "Epoch: 17030/20000, Loss: 0.0000014422223558\n",
      "Epoch: 17040/20000, Loss: 0.0000015845370172\n",
      "Epoch: 17050/20000, Loss: 0.0000046487275540\n",
      "Epoch: 17060/20000, Loss: 0.0000127671801238\n",
      "Epoch: 17070/20000, Loss: 0.0000103517259049\n",
      "Epoch: 17080/20000, Loss: 0.0000085383999249\n",
      "Epoch: 17090/20000, Loss: 0.0000033328885820\n",
      "Epoch: 17100/20000, Loss: 0.0000019684634935\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 17110/20000, Loss: 0.0000018265252493\n",
      "Epoch: 17120/20000, Loss: 0.0000015471379129\n",
      "Epoch: 17130/20000, Loss: 0.0000023766599497\n",
      "Epoch: 17140/20000, Loss: 0.0000192040297406\n",
      "Epoch: 17150/20000, Loss: 0.0000062919120865\n",
      "Epoch: 17160/20000, Loss: 0.0000047562721193\n",
      "Epoch: 17170/20000, Loss: 0.0000022503645596\n",
      "Epoch: 17180/20000, Loss: 0.0000014286800933\n",
      "Epoch: 17190/20000, Loss: 0.0000013780528434\n",
      "Epoch: 17200/20000, Loss: 0.0000013778849279\n",
      "Epoch: 17210/20000, Loss: 0.0000017174022560\n",
      "Epoch: 17220/20000, Loss: 0.0000122549618027\n",
      "Epoch: 17230/20000, Loss: 0.0000139396079248\n",
      "Epoch: 17240/20000, Loss: 0.0000056159819906\n",
      "Epoch: 17250/20000, Loss: 0.0000022337592327\n",
      "Epoch: 17260/20000, Loss: 0.0000019541373604\n",
      "Epoch: 17270/20000, Loss: 0.0000014852919321\n",
      "Epoch: 17280/20000, Loss: 0.0000013687165392\n",
      "Epoch: 17290/20000, Loss: 0.0000016500197262\n",
      "Epoch: 17300/20000, Loss: 0.0000101523164631\n",
      "Epoch: 17310/20000, Loss: 0.0000057444485719\n",
      "Epoch: 17320/20000, Loss: 0.0000041821308514\n",
      "Epoch: 17330/20000, Loss: 0.0000059716567193\n",
      "Epoch: 17340/20000, Loss: 0.0000064568807829\n",
      "Epoch: 17350/20000, Loss: 0.0000023100142243\n",
      "Epoch: 17360/20000, Loss: 0.0000023067470920\n",
      "Epoch: 17370/20000, Loss: 0.0000021681814815\n",
      "Epoch: 17380/20000, Loss: 0.0000026647157938\n",
      "Epoch: 17390/20000, Loss: 0.0000087552089099\n",
      "Epoch: 17400/20000, Loss: 0.0000042203278099\n",
      "Epoch: 17410/20000, Loss: 0.0000105736316982\n",
      "Epoch: 17420/20000, Loss: 0.0000113036539915\n",
      "Epoch: 17430/20000, Loss: 0.0000039506671783\n",
      "Epoch: 17440/20000, Loss: 0.0000018196125211\n",
      "Epoch: 17450/20000, Loss: 0.0000015330278984\n",
      "Epoch: 17460/20000, Loss: 0.0000014099795180\n",
      "Epoch: 17470/20000, Loss: 0.0000013173615798\n",
      "Epoch: 17480/20000, Loss: 0.0000013292607264\n",
      "Epoch: 17490/20000, Loss: 0.0000028156318876\n",
      "Epoch: 17500/20000, Loss: 0.0000203647778108\n",
      "Epoch: 17510/20000, Loss: 0.0000143629022205\n",
      "Epoch: 17520/20000, Loss: 0.0000077560434875\n",
      "Epoch: 17530/20000, Loss: 0.0000040748514039\n",
      "Epoch: 17540/20000, Loss: 0.0000017473004164\n",
      "Epoch: 17550/20000, Loss: 0.0000015474048496\n",
      "Epoch: 17560/20000, Loss: 0.0000014577402681\n",
      "Epoch: 17570/20000, Loss: 0.0000017016086531\n",
      "Epoch: 17580/20000, Loss: 0.0000114798840514\n",
      "Epoch: 17590/20000, Loss: 0.0000031331742321\n",
      "Epoch: 17600/20000, Loss: 0.0000062100280047\n",
      "Epoch: 17610/20000, Loss: 0.0000061742466642\n",
      "Epoch: 17620/20000, Loss: 0.0000027971182135\n",
      "Epoch: 17630/20000, Loss: 0.0000025093429485\n",
      "Epoch: 17640/20000, Loss: 0.0000089851509983\n",
      "Epoch: 17650/20000, Loss: 0.0000043357649702\n",
      "Epoch: 17660/20000, Loss: 0.0000028483891583\n",
      "Epoch: 17670/20000, Loss: 0.0000019755400444\n",
      "Epoch: 17680/20000, Loss: 0.0000014547370029\n",
      "Epoch: 17690/20000, Loss: 0.0000016078562339\n",
      "Epoch: 17700/20000, Loss: 0.0000064360483520\n",
      "Epoch: 17710/20000, Loss: 0.0000192373663594\n",
      "Epoch: 17720/20000, Loss: 0.0000035817604385\n",
      "Epoch: 17730/20000, Loss: 0.0000032834557260\n",
      "Epoch: 17740/20000, Loss: 0.0000016584209561\n",
      "Epoch: 17750/20000, Loss: 0.0000015331959275\n",
      "Epoch: 17760/20000, Loss: 0.0000016034193777\n",
      "Epoch: 17770/20000, Loss: 0.0000067674686761\n",
      "Epoch: 17780/20000, Loss: 0.0000096476114777\n",
      "Epoch: 17790/20000, Loss: 0.0000033597866604\n",
      "Epoch: 17800/20000, Loss: 0.0000018634025309\n",
      "Epoch: 17810/20000, Loss: 0.0000016554537297\n",
      "Epoch: 17820/20000, Loss: 0.0000038510661398\n",
      "Epoch: 17830/20000, Loss: 0.0000143298466355\n",
      "Epoch: 17840/20000, Loss: 0.0000038835423766\n",
      "Epoch: 17850/20000, Loss: 0.0000018938669655\n",
      "Epoch: 17860/20000, Loss: 0.0000015603602606\n",
      "Epoch: 17870/20000, Loss: 0.0000014958740167\n",
      "Epoch: 17880/20000, Loss: 0.0000034597962895\n",
      "Epoch: 17890/20000, Loss: 0.0000306928559439\n",
      "Epoch: 17900/20000, Loss: 0.0000105977715066\n",
      "Epoch: 17910/20000, Loss: 0.0000042571250560\n",
      "Epoch: 17920/20000, Loss: 0.0000024705780106\n",
      "Epoch: 17930/20000, Loss: 0.0000015025669882\n",
      "Epoch: 17940/20000, Loss: 0.0000014151643200\n",
      "Epoch: 17950/20000, Loss: 0.0000013360311186\n",
      "Epoch: 17960/20000, Loss: 0.0000016315382254\n",
      "Epoch: 17970/20000, Loss: 0.0000103389129436\n",
      "Epoch: 17980/20000, Loss: 0.0000067435439632\n",
      "Epoch: 17990/20000, Loss: 0.0000036235874177\n",
      "Epoch: 18000/20000, Loss: 0.0000060842808125\n",
      "Epoch: 18010/20000, Loss: 0.0000073031133070\n",
      "Epoch: 18020/20000, Loss: 0.0000025635479233\n",
      "Epoch: 18030/20000, Loss: 0.0000015389604187\n",
      "Epoch: 18040/20000, Loss: 0.0000015843346546\n",
      "Epoch: 18050/20000, Loss: 0.0000017731773596\n",
      "Epoch: 18060/20000, Loss: 0.0000046459713303\n",
      "Epoch: 18070/20000, Loss: 0.0000133760468088\n",
      "Epoch: 18080/20000, Loss: 0.0000036144986097\n",
      "Epoch: 18090/20000, Loss: 0.0000030848177630\n",
      "Epoch: 18100/20000, Loss: 0.0000063232191678\n",
      "Epoch: 18110/20000, Loss: 0.0000068644235398\n",
      "Epoch: 18120/20000, Loss: 0.0000026257193895\n",
      "Epoch: 18130/20000, Loss: 0.0000021714881768\n",
      "Epoch: 18140/20000, Loss: 0.0000067496353040\n",
      "Epoch: 18150/20000, Loss: 0.0000064003329499\n",
      "Epoch: 18160/20000, Loss: 0.0000053098124226\n",
      "Epoch: 18170/20000, Loss: 0.0000014965866058\n",
      "Epoch: 18180/20000, Loss: 0.0000020300824417\n",
      "Epoch: 18190/20000, Loss: 0.0000028003498755\n",
      "Epoch: 18200/20000, Loss: 0.0000076569758676\n",
      "Epoch: 18210/20000, Loss: 0.0000060413126448\n",
      "Epoch: 18220/20000, Loss: 0.0000042351207412\n",
      "Epoch: 18230/20000, Loss: 0.0000023431077807\n",
      "Epoch: 18240/20000, Loss: 0.0000077726635936\n",
      "Epoch: 18250/20000, Loss: 0.0000038866555769\n",
      "Epoch: 18260/20000, Loss: 0.0000037467789298\n",
      "Epoch: 18270/20000, Loss: 0.0000049848949857\n",
      "Epoch: 18280/20000, Loss: 0.0000081568759924\n",
      "Epoch: 18290/20000, Loss: 0.0000076624000940\n",
      "Epoch: 18300/20000, Loss: 0.0000027257817692\n",
      "Epoch: 18310/20000, Loss: 0.0000018253393819\n",
      "Epoch: 18320/20000, Loss: 0.0000016510967953\n",
      "Epoch: 18330/20000, Loss: 0.0000022941835596\n",
      "Epoch: 18340/20000, Loss: 0.0000125427604871\n",
      "Epoch: 18350/20000, Loss: 0.0000064750347519\n",
      "Epoch: 18360/20000, Loss: 0.0000041676194087\n",
      "Epoch: 18370/20000, Loss: 0.0000020376876364\n",
      "Epoch: 18380/20000, Loss: 0.0000016683081867\n",
      "Epoch: 18390/20000, Loss: 0.0000014258504279\n",
      "Epoch: 18400/20000, Loss: 0.0000014610960761\n",
      "Epoch: 18410/20000, Loss: 0.0000088100541689\n",
      "Epoch: 18420/20000, Loss: 0.0000125741134980\n",
      "Epoch: 18430/20000, Loss: 0.0000067938403845\n",
      "Epoch: 18440/20000, Loss: 0.0000029733187148\n",
      "Epoch: 18450/20000, Loss: 0.0000016986380160\n",
      "Epoch: 18460/20000, Loss: 0.0000014849455283\n",
      "Epoch: 18470/20000, Loss: 0.0000013942802752\n",
      "Epoch: 18480/20000, Loss: 0.0000019502904252\n",
      "Epoch: 18490/20000, Loss: 0.0000122491883303\n",
      "Epoch: 18500/20000, Loss: 0.0000052018835959\n",
      "Epoch: 18510/20000, Loss: 0.0000029407533475\n",
      "Epoch: 18520/20000, Loss: 0.0000076633923527\n",
      "Epoch: 18530/20000, Loss: 0.0000023003465230\n",
      "Epoch: 18540/20000, Loss: 0.0000018523709286\n",
      "Epoch: 18550/20000, Loss: 0.0000017558702439\n",
      "Epoch: 18560/20000, Loss: 0.0000021882297006\n",
      "Epoch: 18570/20000, Loss: 0.0000091494221124\n",
      "Epoch: 18580/20000, Loss: 0.0000106917250378\n",
      "Epoch: 18590/20000, Loss: 0.0000040936856749\n",
      "Epoch: 18600/20000, Loss: 0.0000027119797323\n",
      "Epoch: 18610/20000, Loss: 0.0000015180982018\n",
      "Epoch: 18620/20000, Loss: 0.0000014688562260\n",
      "Epoch: 18630/20000, Loss: 0.0000014581967207\n",
      "Epoch: 18640/20000, Loss: 0.0000083054974311\n",
      "Epoch: 18650/20000, Loss: 0.0000051327847359\n",
      "Epoch: 18660/20000, Loss: 0.0000045003885134\n",
      "Epoch: 18670/20000, Loss: 0.0000031104548270\n",
      "Epoch: 18680/20000, Loss: 0.0000046802751967\n",
      "Epoch: 18690/20000, Loss: 0.0000067347618824\n",
      "Epoch: 18700/20000, Loss: 0.0000027313205919\n",
      "Epoch: 18710/20000, Loss: 0.0000026374316349\n",
      "Epoch: 18720/20000, Loss: 0.0000018044036096\n",
      "Epoch: 18730/20000, Loss: 0.0000029590019039\n",
      "Epoch: 18740/20000, Loss: 0.0000108163840196\n",
      "Epoch: 18750/20000, Loss: 0.0000032639234178\n",
      "Epoch: 18760/20000, Loss: 0.0000040230038394\n",
      "Epoch: 18770/20000, Loss: 0.0000070390774454\n",
      "Epoch: 18780/20000, Loss: 0.0000049098935051\n",
      "Epoch: 18790/20000, Loss: 0.0000038325570131\n",
      "Epoch: 18800/20000, Loss: 0.0000018157553541\n",
      "Epoch: 18810/20000, Loss: 0.0000013874040405\n",
      "Epoch: 18820/20000, Loss: 0.0000014437950995\n",
      "Epoch: 18830/20000, Loss: 0.0000028452545848\n",
      "Epoch: 18840/20000, Loss: 0.0000182955554919\n",
      "Epoch: 18850/20000, Loss: 0.0000128586470964\n",
      "Epoch: 18860/20000, Loss: 0.0000032449204355\n",
      "Epoch: 18870/20000, Loss: 0.0000027631629109\n",
      "Epoch: 18880/20000, Loss: 0.0000016724465013\n",
      "Epoch: 18890/20000, Loss: 0.0000013086408899\n",
      "Epoch: 18900/20000, Loss: 0.0000012710045212\n",
      "Epoch: 18910/20000, Loss: 0.0000017998874000\n",
      "Epoch: 18920/20000, Loss: 0.0000072099510362\n",
      "Epoch: 18930/20000, Loss: 0.0000063975758167\n",
      "Epoch: 18940/20000, Loss: 0.0000070535629675\n",
      "Epoch: 18950/20000, Loss: 0.0000081636544564\n",
      "Epoch: 18960/20000, Loss: 0.0000025799517971\n",
      "Epoch: 18970/20000, Loss: 0.0000015018553086\n",
      "Epoch: 18980/20000, Loss: 0.0000015530249584\n",
      "Epoch: 18990/20000, Loss: 0.0000017880286123\n",
      "Epoch: 19000/20000, Loss: 0.0000076865444498\n",
      "Epoch: 19010/20000, Loss: 0.0000043089839892\n",
      "Epoch: 19020/20000, Loss: 0.0000047115950110\n",
      "Epoch: 19030/20000, Loss: 0.0000040468612497\n",
      "Epoch: 19040/20000, Loss: 0.0000068929189183\n",
      "Epoch: 19050/20000, Loss: 0.0000083814920799\n",
      "Epoch: 19060/20000, Loss: 0.0000019119065655\n",
      "Epoch: 19070/20000, Loss: 0.0000023369166229\n",
      "Epoch: 19080/20000, Loss: 0.0000015333839656\n",
      "Epoch: 19090/20000, Loss: 0.0000014064791003\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Epoch: 19100/20000, Loss: 0.0000015636430817\n",
      "Epoch: 19110/20000, Loss: 0.0000118324051073\n",
      "Epoch: 19120/20000, Loss: 0.0000079994315456\n",
      "Epoch: 19130/20000, Loss: 0.0000064788632699\n",
      "Epoch: 19140/20000, Loss: 0.0000019245057956\n",
      "Epoch: 19150/20000, Loss: 0.0000017786588842\n",
      "Epoch: 19160/20000, Loss: 0.0000013928739691\n",
      "Epoch: 19170/20000, Loss: 0.0000020999418666\n",
      "Epoch: 19180/20000, Loss: 0.0000137258821269\n",
      "Epoch: 19190/20000, Loss: 0.0000034312965909\n",
      "Epoch: 19200/20000, Loss: 0.0000026312939099\n",
      "Epoch: 19210/20000, Loss: 0.0000025204301437\n",
      "Epoch: 19220/20000, Loss: 0.0000020871634661\n",
      "Epoch: 19230/20000, Loss: 0.0000020790600956\n",
      "Epoch: 19240/20000, Loss: 0.0000080383342720\n",
      "Epoch: 19250/20000, Loss: 0.0000044626244744\n",
      "Epoch: 19260/20000, Loss: 0.0000039877563722\n",
      "Epoch: 19270/20000, Loss: 0.0000047009025366\n",
      "Epoch: 19280/20000, Loss: 0.0000050418543651\n",
      "Epoch: 19290/20000, Loss: 0.0000033403925954\n",
      "Epoch: 19300/20000, Loss: 0.0000019839737888\n",
      "Epoch: 19310/20000, Loss: 0.0000016131285747\n",
      "Epoch: 19320/20000, Loss: 0.0000115309003377\n",
      "Epoch: 19330/20000, Loss: 0.0000145716676343\n",
      "Epoch: 19340/20000, Loss: 0.0000056777544160\n",
      "Epoch: 19350/20000, Loss: 0.0000025308756904\n",
      "Epoch: 19360/20000, Loss: 0.0000013737868585\n",
      "Epoch: 19370/20000, Loss: 0.0000013495134681\n",
      "Epoch: 19380/20000, Loss: 0.0000017989899561\n",
      "Epoch: 19390/20000, Loss: 0.0000114008253149\n",
      "Epoch: 19400/20000, Loss: 0.0000050527960411\n",
      "Epoch: 19410/20000, Loss: 0.0000073235037235\n",
      "Epoch: 19420/20000, Loss: 0.0000021964297048\n",
      "Epoch: 19430/20000, Loss: 0.0000012519790289\n",
      "Epoch: 19440/20000, Loss: 0.0000013635733467\n",
      "Epoch: 19450/20000, Loss: 0.0000013748516494\n",
      "Epoch: 19460/20000, Loss: 0.0000094589486253\n",
      "Epoch: 19470/20000, Loss: 0.0000076560345406\n",
      "Epoch: 19480/20000, Loss: 0.0000048248343774\n",
      "Epoch: 19490/20000, Loss: 0.0000018439133100\n",
      "Epoch: 19500/20000, Loss: 0.0000016487647372\n",
      "Epoch: 19510/20000, Loss: 0.0000037709789922\n",
      "Epoch: 19520/20000, Loss: 0.0000109628708742\n",
      "Epoch: 19530/20000, Loss: 0.0000033508119941\n",
      "Epoch: 19540/20000, Loss: 0.0000018456152020\n",
      "Epoch: 19550/20000, Loss: 0.0000026736890959\n",
      "Epoch: 19560/20000, Loss: 0.0000080752452050\n",
      "Epoch: 19570/20000, Loss: 0.0000042286051212\n",
      "Epoch: 19580/20000, Loss: 0.0000031319939353\n",
      "Epoch: 19590/20000, Loss: 0.0000019202857402\n",
      "Epoch: 19600/20000, Loss: 0.0000014496155245\n",
      "Epoch: 19610/20000, Loss: 0.0000014867421214\n",
      "Epoch: 19620/20000, Loss: 0.0000079360806922\n",
      "Epoch: 19630/20000, Loss: 0.0000153721448442\n",
      "Epoch: 19640/20000, Loss: 0.0000033758137761\n",
      "Epoch: 19650/20000, Loss: 0.0000034158149447\n",
      "Epoch: 19660/20000, Loss: 0.0000019118306227\n",
      "Epoch: 19670/20000, Loss: 0.0000012015149196\n",
      "Epoch: 19680/20000, Loss: 0.0000011183676634\n",
      "Epoch: 19690/20000, Loss: 0.0000011898156345\n",
      "Epoch: 19700/20000, Loss: 0.0000051709002946\n",
      "Epoch: 19710/20000, Loss: 0.0000069189359237\n",
      "Epoch: 19720/20000, Loss: 0.0000071542954174\n",
      "Epoch: 19730/20000, Loss: 0.0000033119774798\n",
      "Epoch: 19740/20000, Loss: 0.0000017813404156\n",
      "Epoch: 19750/20000, Loss: 0.0000019224955849\n",
      "Epoch: 19760/20000, Loss: 0.0000064439623202\n",
      "Epoch: 19770/20000, Loss: 0.0000104529844975\n",
      "Epoch: 19780/20000, Loss: 0.0000048239880925\n",
      "Epoch: 19790/20000, Loss: 0.0000022179190182\n",
      "Epoch: 19800/20000, Loss: 0.0000013512127452\n",
      "Epoch: 19810/20000, Loss: 0.0000011509545175\n",
      "Epoch: 19820/20000, Loss: 0.0000021184400794\n",
      "Epoch: 19830/20000, Loss: 0.0000242059868469\n",
      "Epoch: 19840/20000, Loss: 0.0000102312287709\n",
      "Epoch: 19850/20000, Loss: 0.0000029030438782\n",
      "Epoch: 19860/20000, Loss: 0.0000019439119114\n",
      "Epoch: 19870/20000, Loss: 0.0000012722846350\n",
      "Epoch: 19880/20000, Loss: 0.0000010810465483\n",
      "Epoch: 19890/20000, Loss: 0.0000010365730532\n",
      "Epoch: 19900/20000, Loss: 0.0000012096130604\n",
      "Epoch: 19910/20000, Loss: 0.0000083284112407\n",
      "Epoch: 19920/20000, Loss: 0.0000050949784054\n",
      "Epoch: 19930/20000, Loss: 0.0000035636624034\n",
      "Epoch: 19940/20000, Loss: 0.0000024689404654\n",
      "Epoch: 19950/20000, Loss: 0.0000028737101729\n",
      "Epoch: 19960/20000, Loss: 0.0000091235096988\n",
      "Epoch: 19970/20000, Loss: 0.0000018094813186\n",
      "Epoch: 19980/20000, Loss: 0.0000021922357973\n",
      "Epoch: 19990/20000, Loss: 0.0000038193779801\n",
      "Epoch: 20000/20000, Loss: 0.0000094071165222\n"
     ]
    }
   ],
   "source": [
    "# Create LEM instance\n",
    "lem = LEM(input_size, hidden_size, output_size, dt=0.9)\n",
    "\n",
    "# Loss and optimizer\n",
    "criterion = nn.MSELoss()\n",
    "optimizer = torch.optim.Adam(lem.parameters(), lr=0.001)\n",
    "\n",
    "# Training loop\n",
    "for epoch in range(num_epochs):\n",
    "    # Forward pass\n",
    "    output = lem(input_tensor)\n",
    "    loss = criterion(output, target_tensor)\n",
    "\n",
    "    # Backward and optimize\n",
    "    optimizer.zero_grad()\n",
    "    loss.backward()\n",
    "    optimizer.step()\n",
    "\n",
    "    # Print progress\n",
    "    if (epoch + 1) % 10 == 0:\n",
    "        print(f'Epoch: {epoch + 1}/{num_epochs}, Loss: {loss.item():.16f}')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "id": "1da66d64",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "torch.Size([1, 1, 256])\n",
      "torch.Size([1, 20, 256])\n"
     ]
    }
   ],
   "source": [
    "print(test_tensor.shape)\n",
    "prediction_tensor = torch.zeros(1, 20, 256).float()\n",
    "print(prediction_tensor.shape)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "id": "a0543daa",
   "metadata": {},
   "outputs": [],
   "source": [
    "with torch.no_grad():\n",
    "    prediction = lem(test_tensor)\n",
    "    prediction = prediction.view(1, 1, 256).float()\n",
    "    prediction_tensor[:, 0, :] = prediction\n",
    "    for i in range(19):\n",
    "        prediction = lem(prediction)\n",
    "        prediction = prediction.view(1, 1, 256).float()\n",
    "        prediction_tensor[:, i+1, :] = prediction\n",
    "        "
   ]
  },
  {
   "cell_type": "markdown",
   "id": "2e6b9bad",
   "metadata": {},
   "source": [
    "### Four different types of error"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "id": "9c33b0f5",
   "metadata": {},
   "outputs": [],
   "source": [
    "# Exact Solution\n",
    "\n",
    "u_test = u_1.T\n",
    "u_test_full = u_test[80:100, :]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "id": "00c8fa22",
   "metadata": {},
   "outputs": [],
   "source": [
    "prediction_tensor = torch.squeeze(prediction_tensor)\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "id": "334bf0be",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "torch.Size([20, 256])"
      ]
     },
     "execution_count": 13,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "# Extrapolation\n",
    "\n",
    "k1 = ( prediction_tensor - u_test_full)**2\n",
    "u_test_full_tensor = torch.tensor(u_test_full**2)\n",
    "u_test_full_tensor.shape"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "01080c4f",
   "metadata": {},
   "source": [
    "### L^2 norm error"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "id": "33c17bd8",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Relative Error Test:  0.06202654228340688 %\n"
     ]
    }
   ],
   "source": [
    "# Compute the relative L2 error norm (generalization error)\n",
    "relative_error_test = torch.mean(k1)/ torch.mean(u_test_full_tensor)\n",
    "\n",
    "print(\"Relative Error Test: \", relative_error_test.item(), \"%\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "id": "6b26fe7a",
   "metadata": {},
   "outputs": [
    {
     "ename": "SyntaxError",
     "evalue": "invalid syntax (4209523232.py, line 1)",
     "output_type": "error",
     "traceback": [
      "\u001b[0;36m  File \u001b[0;32m\"/tmp/ipykernel_24529/4209523232.py\"\u001b[0;36m, line \u001b[0;32m1\u001b[0m\n\u001b[0;31m    2+\u001b[0m\n\u001b[0m      ^\u001b[0m\n\u001b[0;31mSyntaxError\u001b[0m\u001b[0;31m:\u001b[0m invalid syntax\n"
     ]
    }
   ],
   "source": [
    "2+"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "fa3fa35b",
   "metadata": {},
   "source": [
    "### Max absolute norm error"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "01cf8637",
   "metadata": {},
   "outputs": [],
   "source": [
    "R_abs = torch.max(torch.abs(prediction_tensor - u_test_full))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "b3e65482",
   "metadata": {},
   "outputs": [],
   "source": [
    "print(R_abs)"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "678810f2",
   "metadata": {},
   "source": [
    "### Explained variance score"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "02c72385",
   "metadata": {},
   "outputs": [],
   "source": [
    "import torch\n",
    "\n",
    "a = prediction_tensor\n",
    "b = u_test_full\n",
    "# Assuming 'a' is your predicted values (model's predictions) and 'b' is the true values (ground truth)\n",
    "# Make sure 'a' and 'b' are PyTorch tensors\n",
    "# a = torch.tensor(a)\n",
    "b = torch.tensor(b)\n",
    "# Calculate the mean of 'b'\n",
    "mean_b = torch.mean(b)\n",
    "\n",
    "# Calculate the Explained Variance Score\n",
    "numerator = torch.var(b - a)  # Variance of the differences between 'b' and 'a'\n",
    "denominator = torch.var(b)    # Variance of 'b'\n",
    "evs = 1 - numerator / denominator\n",
    "\n",
    "print(\"Explained Variance Score:\", evs.item())"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "f664baf6",
   "metadata": {},
   "source": [
    "### Mean absolute error"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "43fc2394",
   "metadata": {},
   "outputs": [],
   "source": [
    "# Compute the relative L2 error norm (generalization error)\n",
    "relative_error_test = torch.mean(torch.abs(prediction_tensor - u_test_full))\n",
    "\n",
    "print(\"Relative Error Test: \", relative_error_test, \"%\")"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "75e50e9e",
   "metadata": {},
   "source": [
    "### Contour plot for PINN (80 percent) and (20 percentage lem prediction)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "8e3eec75",
   "metadata": {},
   "outputs": [],
   "source": [
    "print(prediction_tensor.shape)\n",
    "prediction_tensor = torch.squeeze(prediction_tensor)\n",
    "input_tensor = torch.squeeze(input_tensor)\n",
    "\n",
    "conc_u = torch.squeeze(input_tensor)\n",
    "concatenated_tensor = torch.cat((conc_u, prediction_tensor), dim=0)\n",
    "\n",
    "x1 = np.linspace(-1, 1, 256)\n",
    "t1 = np.linspace(0, 1, 99)"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "e393a1e0",
   "metadata": {},
   "source": [
    "### Snapshot time plots"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "04f91104",
   "metadata": {},
   "outputs": [],
   "source": [
    "import matplotlib.pyplot as plt\n",
    "import numpy as np\n",
    "import torch\n",
    "\n",
    "# Create the figure and axis objects with reduced width\n",
    "fig, ax = plt.subplots(figsize=(5, 5))  # You can adjust the width (7 inches) and height (5 inches) as needed\n",
    "\n",
    "\n",
    "\n",
    "\n",
    "final_time_output = prediction_tensor[3, :]\n",
    "final_out = final_time_output.detach().numpy().reshape(-1, 1)\n",
    "final_true = u_1[:, 83].reshape(-1, 1)\n",
    "\n",
    "# Plot the data with red and blue lines, one with dotted and one with solid style\n",
    "ax.plot(x, final_out, color='red', linestyle='dotted', linewidth=12, label='Prediction')\n",
    "ax.plot(x, final_true, color='blue', linestyle='solid', linewidth=7, label='True')\n",
    "\n",
    "\n",
    "# Set the axis labels with bold font weight\n",
    "ax.set_xlabel(r\"${x}$\", fontsize=26, color='black', fontdict={'weight': 'bold'})\n",
    "ax.set_ylabel(r\"${u(x, t)}$\", fontsize=26, color='black', fontdict={'weight': 'bold'})\n",
    "\n",
    "# Set the title with bold font weight\n",
    "ax.set_title(r\"${t = 0.83}$\", fontsize=26, color='black', fontweight='bold')\n",
    "\n",
    "# Set the number of ticks for x-axis and y-axis to 3\n",
    "ax.set_xticks([-1, 0, 1])\n",
    "ax.set_yticks([-1, 0, 1])\n",
    "\n",
    "# Set tick labels fontweight to bold and increase font size\n",
    "ax.tick_params(axis='both', which='major', labelsize=20, width=2, length=10)\n",
    "\n",
    "# # Set the fontweight for tick labels to bold\n",
    "# for tick in ax.get_xticklabels() + ax.get_yticklabels():\n",
    "#     tick.set_weight('bold')\n",
    "\n",
    "# Set the spines linewidth to bold\n",
    "ax.spines['top'].set_linewidth(2)\n",
    "ax.spines['right'].set_linewidth(2)\n",
    "ax.spines['bottom'].set_linewidth(2)\n",
    "ax.spines['left'].set_linewidth(2)\n",
    "\n",
    "# Set the legend\n",
    "# ax.legend()\n",
    "\n",
    "plt.savefig('LEM_0.83_20.pdf', dpi=500, bbox_inches=\"tight\")\n",
    "#plt.savefig('lem_0.83_20.png', dpi=500, bbox_inches=\"tight\")\n",
    "# Show the plot\n",
    "plt.show()\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "3d96305e",
   "metadata": {},
   "outputs": [],
   "source": [
    "import matplotlib.pyplot as plt\n",
    "import numpy as np\n",
    "import torch\n",
    "\n",
    "# Create the figure and axis objects with reduced width\n",
    "fig, ax = plt.subplots(figsize=(5, 5))  # You can adjust the width (7 inches) and height (5 inches) as needed\n",
    "\n",
    "\n",
    "\n",
    "final_time_output = prediction_tensor[-2, :]\n",
    "final_out = final_time_output.detach().numpy().reshape(-1, 1)\n",
    "final_true = u_1[:, -2].reshape(-1, 1)\n",
    "\n",
    "# Plot the data with red and blue lines, one with dotted and one with solid style\n",
    "ax.plot(x, final_out, color='red', linestyle='dotted', linewidth=12, label='Prediction')\n",
    "ax.plot(x, final_true, color='blue', linestyle='solid', linewidth=7, label='True')\n",
    "\n",
    "\n",
    "# Set the axis labels with bold font weight\n",
    "ax.set_xlabel(r\"${x}$\", fontsize=26, color='black', fontdict={'weight': 'bold'})\n",
    "ax.set_ylabel(r\"${u(x, t)}$\", fontsize=26, color='black', fontdict={'weight': 'bold'})\n",
    "\n",
    "# Set the title with bold font weight\n",
    "ax.set_title(r\"${t = 0.98}$\", fontsize=26, color='black', fontweight='bold')\n",
    "\n",
    "# Set the number of ticks for x-axis and y-axis to 3\n",
    "ax.set_xticks([-1, 0, 1])\n",
    "ax.set_yticks([-1, 0, 1])\n",
    "\n",
    "# Set tick labels fontweight to bold and increase font size\n",
    "ax.tick_params(axis='both', which='major', labelsize=20, width=2, length=10)\n",
    "\n",
    "# # Set the fontweight for tick labels to bold\n",
    "# for tick in ax.get_xticklabels() + ax.get_yticklabels():\n",
    "#     tick.set_weight('bold')\n",
    "\n",
    "# Set the spines linewidth to bold\n",
    "ax.spines['top'].set_linewidth(2)\n",
    "ax.spines['right'].set_linewidth(2)\n",
    "ax.spines['bottom'].set_linewidth(2)\n",
    "ax.spines['left'].set_linewidth(2)\n",
    "\n",
    "# Set the legend\n",
    "# ax.legend()\n",
    "\n",
    "plt.savefig('LEM_0.98_20.pdf', dpi=500, bbox_inches=\"tight\")\n",
    "#plt.savefig('lem_0.98_20.png', dpi=500, bbox_inches=\"tight\")\n",
    "# Show the plot\n",
    "plt.show()\n"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "d962cd38",
   "metadata": {},
   "source": [
    "### Contour plot where 80 percent for PINN solution and 20 percent for lem solution"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "5011fef9",
   "metadata": {},
   "source": [
    "### Exact contour"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "8d6ac2bb",
   "metadata": {},
   "outputs": [],
   "source": [
    "import torch\n",
    "import numpy as np\n",
    "import matplotlib.pyplot as plt\n",
    "from matplotlib.ticker import FixedLocator\n",
    "\n",
    "# Assuming you have defined concatenated_tensor as a PyTorch tensor\n",
    "# concatenated_tensor = torch.cat((tensor1, tensor2), dim=0)\n",
    "\n",
    "# Convert concatenated_tensor to a NumPy array\n",
    "concatenated_array = u_1.T\n",
    "\n",
    "# Define custom color levels\n",
    "x = np.linspace(-1, 1, concatenated_array.shape[1])  # Replace 0 and 1 with your actual x range\n",
    "t = np.linspace(0, 1, concatenated_array.shape[0])  # Replace 0 and 1 with your actual t range\n",
    "X, T = np.meshgrid(x, t)\n",
    "\n",
    "# Define custom color levels using the minimum and maximum from the NumPy array\n",
    "c_levels = np.linspace(np.min(concatenated_array), np.max(concatenated_array), 400)\n",
    "\n",
    "# Plot the contour with interpolated data\n",
    "plt.figure(figsize=(20, 5))\n",
    "plt.pcolormesh(T, X, concatenated_array, shading='auto', cmap='coolwarm')\n",
    "\n",
    "# Set the fontweight for axis labels to regular (not bold)\n",
    "plt.xlabel(\"$t$\", fontsize=26)\n",
    "plt.ylabel(\"$x$\", fontsize=26)\n",
    "plt.title(\"$u(x, t)$\", fontsize=26)\n",
    "\n",
    "# Set tick labels fontweight to regular (not bold) and increase font size\n",
    "plt.tick_params(axis='both', which='major', labelsize=20, width=3, length=10)\n",
    "\n",
    "# Set the fontweight for tick labels to regular (not bold)\n",
    "for tick in plt.gca().get_xticklabels() + plt.gca().get_yticklabels():\n",
    "    tick.set_weight('normal')\n",
    "\n",
    "# Set the number of ticks for x-axis and y-axis to 5\n",
    "num_ticks = 5\n",
    "x_ticks = np.linspace(np.min(T), np.max(T), num_ticks)\n",
    "y_ticks = np.linspace(np.min(X), np.max(X), num_ticks)\n",
    "\n",
    "plt.gca().xaxis.set_major_locator(FixedLocator(x_ticks))\n",
    "plt.gca().yaxis.set_major_locator(FixedLocator(y_ticks))\n",
    "\n",
    "cbar1 = plt.colorbar()\n",
    "# Set the number of ticks for the color bar with uniformly distributed numbers\n",
    "num_ticks = 5\n",
    "c_ticks = np.linspace(np.min(concatenated_array), np.max(concatenated_array), num_ticks)\n",
    "cbar1.set_ticks(c_ticks)\n",
    "\n",
    "# Set the fontweight and fontsize for color bar tick labels\n",
    "for t in cbar1.ax.get_yticklabels():\n",
    "    t.set_weight('normal')\n",
    "    t.set_fontsize(26)  # Increase the font size for color bar tick labels\n",
    "\n",
    "# Increase the size of numbers on axis and color bar\n",
    "plt.xticks(fontsize=26)\n",
    "plt.yticks(fontsize=26)\n",
    "\n",
    "# Increase the tick size and width of the color bar\n",
    "cbar1.ax.tick_params(axis='both', which='major', labelsize=30, width=3,  length=10)\n",
    "\n",
    "#plt.savefig('Contour_Exact.pdf', dpi=500, bbox_inches=\"tight\")\n",
    "plt.savefig('contour_exact.jpeg', dpi=500, bbox_inches=\"tight\")\n",
    "# Show the plot\n",
    "plt.show()\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "c034dcf7",
   "metadata": {},
   "outputs": [],
   "source": [
    "import torch\n",
    "import numpy as np\n",
    "import matplotlib.pyplot as plt\n",
    "from matplotlib.ticker import FixedLocator\n",
    "\n",
    "# Assuming you have defined concatenated_tensor as a PyTorch tensor\n",
    "# concatenated_tensor = torch.cat((tensor1, tensor2), dim=0)\n",
    "\n",
    "# Convert concatenated_tensor to a NumPy array\n",
    "concatenated_array = concatenated_tensor.numpy()\n",
    "\n",
    "# Define custom color levels\n",
    "x = np.linspace(-1, 1, concatenated_array.shape[1])  # Replace 0 and 1 with your actual x range\n",
    "t = np.linspace(0, 1, concatenated_array.shape[0])  # Replace 0 and 1 with your actual t range\n",
    "X, T = np.meshgrid(x, t1)\n",
    "\n",
    "# Define custom color levels using the minimum and maximum from the NumPy array\n",
    "c_levels = np.linspace(np.min(concatenated_array), np.max(concatenated_array), 400)\n",
    "\n",
    "# Plot the contour with interpolated data\n",
    "plt.figure(figsize=(20, 5))\n",
    "plt.pcolormesh(T, X, concatenated_array, shading='auto', cmap='coolwarm')\n",
    "\n",
    "# Set the fontweight for axis labels to regular (not bold)\n",
    "plt.xlabel(\"$t$\", fontsize=26)\n",
    "plt.ylabel(\"$x$\", fontsize=26)\n",
    "plt.title(\"$u(x, t)$\", fontsize=26)\n",
    "\n",
    "# Set tick labels fontweight to regular (not bold) and increase font size\n",
    "plt.tick_params(axis='both', which='major', labelsize=20, width=3, length=10)\n",
    "\n",
    "# Set the fontweight for tick labels to regular (not bold)\n",
    "for tick in plt.gca().get_xticklabels() + plt.gca().get_yticklabels():\n",
    "    tick.set_weight('normal')\n",
    "\n",
    "# Set the number of ticks for x-axis and y-axis to 5\n",
    "num_ticks = 5\n",
    "x_ticks = np.linspace(np.min(T), np.max(T), num_ticks)\n",
    "y_ticks = np.linspace(np.min(X), np.max(X), num_ticks)\n",
    "\n",
    "plt.gca().xaxis.set_major_locator(FixedLocator(x_ticks))\n",
    "plt.gca().yaxis.set_major_locator(FixedLocator(y_ticks))\n",
    "\n",
    "cbar1 = plt.colorbar()\n",
    "# Set the number of ticks for the color bar with uniformly distributed numbers\n",
    "num_ticks = 5\n",
    "c_ticks = np.linspace(np.min(concatenated_array), np.max(concatenated_array), num_ticks)\n",
    "cbar1.set_ticks(c_ticks)\n",
    "\n",
    "# Set the fontweight and fontsize for color bar tick labels\n",
    "for t in cbar1.ax.get_yticklabels():\n",
    "    t.set_weight('normal')\n",
    "    t.set_fontsize(26)  # Increase the font size for color bar tick labels\n",
    "\n",
    "# Increase the size of numbers on axis and color bar\n",
    "plt.xticks(fontsize=26)\n",
    "plt.yticks(fontsize=26)\n",
    "\n",
    "# Increase the tick size and width of the color bar\n",
    "cbar1.ax.tick_params(axis='both', which='major', labelsize=30, width=3,  length=10)\n",
    "\n",
    "# Add a dotted line at t = 0.8\n",
    "plt.axvline(x=0.8, color='black', linestyle='dotted', linewidth=5)\n",
    "\n",
    "#plt.savefig('Contour_LEM_20.pdf', dpi=500, bbox_inches=\"tight\")\n",
    "plt.savefig('contour_LEM_20.jpeg', dpi=500, bbox_inches=\"tight\")\n",
    "# Show the plot\n",
    "plt.show()\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "b7ab04a2",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.9.7"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
